[gnome-media/gnome-2-32] Replace deprecated GTK+ symbols



commit 6f198c12f2fdb7137cfda0584017e541194b2f2b
Author: Javier Jardón <jjardon gnome org>
Date:   Thu Apr 15 17:00:32 2010 +0200

    Replace deprecated GTK+ symbols
    
    Replace GTK_WIDGET_STATE() and GTK_WIDGET_TOPLEVEL() macros
    
    https://bugzilla.gnome.org/show_bug.cgi?id=572353

 gst-mixer/src/volume.c               |    7 +++++--
 sound-theme/gvc-sound-theme-editor.c |    2 +-
 2 files changed, 6 insertions(+), 3 deletions(-)
---
diff --git a/gst-mixer/src/volume.c b/gst-mixer/src/volume.c
index c391d6b..c4bb6b4 100644
--- a/gst-mixer/src/volume.c
+++ b/gst-mixer/src/volume.c
@@ -351,6 +351,7 @@ gnome_volume_control_volume_expose (GtkWidget *widget,
 				    GdkEventExpose *expose)
 {
   GnomeVolumeControlVolume *vol = GNOME_VOLUME_CONTROL_VOLUME (widget);
+  GtkStateType state;
 
   /* clear background */
   gdk_window_clear_area (widget->window, 0, 0,
@@ -378,10 +379,12 @@ gnome_volume_control_volume_expose (GtkWidget *widget,
     points[1].y = points[2].y = points[0].y + height - 3;
 
     /* draw chainbutton decorations */
+    state = gtk_widget_get_state (widget);
+
     points[0].x = points[1].x = x_offset + 3;
     points[2].x = points[0].x + width - 6;
     gtk_paint_polygon (widget->style, widget->window,
-		       GTK_WIDGET_STATE (widget),
+		       state,
 		       GTK_SHADOW_ETCHED_IN,
 		       &expose->area, widget, "hseparator",
 		       points, 3, FALSE);
@@ -389,7 +392,7 @@ gnome_volume_control_volume_expose (GtkWidget *widget,
     points[0].x = points[1].x = widget->allocation.width - x_offset - 3;
     points[2].x = points[0].x - width + 6;
     gtk_paint_polygon (widget->style, widget->window,
-		       GTK_WIDGET_STATE (widget),
+		       state,
 		       GTK_SHADOW_ETCHED_IN,
 		       &expose->area, widget, "hseparator",
 		       points, 3, FALSE);
diff --git a/sound-theme/gvc-sound-theme-editor.c b/sound-theme/gvc-sound-theme-editor.c
index 377e628..3a5236a 100644
--- a/sound-theme/gvc-sound-theme-editor.c
+++ b/sound-theme/gvc-sound-theme-editor.c
@@ -585,7 +585,7 @@ get_sound_filename (GvcSoundThemeEditor *editor)
 
 	/* Try to get the parent window of the widget */
 	toplevel = gtk_widget_get_toplevel (GTK_WIDGET (editor));
-	if (GTK_WIDGET_TOPLEVEL (toplevel) != FALSE)
+	if (gtk_widget_is_toplevel (toplevel) != FALSE)
 		parent = GTK_WINDOW (toplevel);
 	else
 		parent = NULL;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]