1 As the rest of Sato is GTK+ 2, patch gtk-play to use GTK+ 2. When the rest of
2 Sato has been ported to GTK+ 3 this patch can be dropped.
4 Upstream-Status: Inappropriate
5 Signed-off-by: Ross Burton <ross.burton@intel.com>
8 diff --git a/configure.ac b/configure.ac
9 index b8af13b..90ab74c 100644
12 @@ -60,7 +60,7 @@ AC_SUBST(GLIB_PREFIX)
13 GST_PREFIX="`$PKG_CONFIG --variable=prefix gstreamer-1.0`"
16 -PKG_CHECK_MODULES(GTK, [gtk+-3.0], [have_gtk="yes"], [have_gtk="no"])
17 +PKG_CHECK_MODULES(GTK, [gtk+-2.0], [have_gtk="yes"], [have_gtk="no"])
18 AM_CONDITIONAL(HAVE_GTK, test "x$have_gtk" != "xno")
20 GOBJECT_INTROSPECTION_CHECK([1.31.1])
21 diff --git a/gtk/gtk-play.c b/gtk/gtk-play.c
22 index f015077..954d6fb 100644
25 @@ -34,6 +34,46 @@ typedef struct
26 gulong seekbar_value_changed_signal_id;
31 +gtk_box_new (GtkOrientation orientation,
34 + switch (orientation) {
35 + case GTK_ORIENTATION_HORIZONTAL:
36 + return gtk_hbox_new (FALSE, spacing);
37 + case GTK_ORIENTATION_VERTICAL:
38 + return gtk_vbox_new (FALSE, spacing);
43 +gtk_button_new_from_icon_name (const gchar *icon_name,
49 + image = gtk_image_new_from_icon_name (icon_name, size);
50 + button = g_object_new (GTK_TYPE_BUTTON,
57 +gtk_scale_new_with_range (GtkOrientation orientation,
62 + switch (orientation) {
63 + case GTK_ORIENTATION_HORIZONTAL:
64 + return gtk_hscale_new_with_range (min, max, step);
65 + case GTK_ORIENTATION_VERTICAL:
66 + return gtk_vscale_new_with_range (min, max, step);
71 set_title (GtkPlay * play, const gchar * title)