]> granicus.if.org Git - handbrake/commitdiff
LinGui: Remove use of deprecated GTK_WIDGET_SENSITIVE and GTK_WIDGET_HAS_FOCUS
authorjstebbins <jstebbins.hb@gmail.com>
Tue, 22 Mar 2011 01:03:17 +0000 (01:03 +0000)
committerjstebbins <jstebbins.hb@gmail.com>
Tue, 22 Mar 2011 01:03:17 +0000 (01:03 +0000)
Replace with gtk_widget_is_sensitive and gtk_widget_has_focus

git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3861 b64f7644-9d1e-0410-96f1-a4d463321fa5

gtk/src/callbacks.c
gtk/src/ghbcellrenderertext.c
gtk/src/x264handler.c

index 8009b3610d6b1b4329d5bcc7b65172a2447035b5..daa5d97efbe4c441964272e4a873aa51684dd95e 100644 (file)
@@ -123,7 +123,7 @@ dep_check(signal_user_data_t *ud, const gchar *name, gboolean *out_hide)
                widget_name = ghb_value_string(ghb_array_get_nth(data, 0));
                widget = GHB_WIDGET(ud->builder, widget_name);
                dep_object = gtk_builder_get_object(ud->builder, name);
-               if (widget != NULL && !GTK_WIDGET_SENSITIVE(widget))
+               if (widget != NULL && !gtk_widget_is_sensitive(widget))
                        continue;
                if (dep_object == NULL)
                {
@@ -1781,7 +1781,7 @@ scale_width_changed_cb(GtkWidget *widget, signal_user_data_t *ud)
        ghb_widget_to_setting(ud->settings, widget);
        ghb_check_dependency(ud, widget, NULL);
        ghb_clear_presets_selection(ud);
-       if (GTK_WIDGET_SENSITIVE(widget))
+       if (gtk_widget_is_sensitive(widget))
                ghb_set_scale (ud, GHB_PIC_KEEP_WIDTH);
        update_preview = TRUE;
        gchar *text;
@@ -1801,7 +1801,7 @@ scale_height_changed_cb(GtkWidget *widget, signal_user_data_t *ud)
        ghb_widget_to_setting(ud->settings, widget);
        ghb_check_dependency(ud, widget, NULL);
        ghb_clear_presets_selection(ud);
-       if (GTK_WIDGET_SENSITIVE(widget))
+       if (gtk_widget_is_sensitive(widget))
                ghb_set_scale (ud, GHB_PIC_KEEP_HEIGHT);
        update_preview = TRUE;
        gchar *text;
@@ -1824,7 +1824,7 @@ crop_changed_cb(GtkWidget *widget, signal_user_data_t *ud)
        ghb_widget_to_setting(ud->settings, widget);
        ghb_check_dependency(ud, widget, NULL);
        ghb_clear_presets_selection(ud);
-       if (GTK_WIDGET_SENSITIVE(widget))
+       if (gtk_widget_is_sensitive(widget))
                ghb_set_scale (ud, 0);
 
        crop[0] = ghb_settings_get_int(ud->settings, "PictureTopCrop");
@@ -1863,7 +1863,7 @@ display_width_changed_cb(GtkWidget *widget, signal_user_data_t *ud)
        ghb_check_dependency(ud, widget, NULL);
        ghb_clear_presets_selection(ud);
        ghb_live_reset(ud);
-       if (GTK_WIDGET_SENSITIVE(widget))
+       if (gtk_widget_is_sensitive(widget))
                ghb_set_scale (ud, GHB_PIC_KEEP_DISPLAY_WIDTH);
 
        update_preview = TRUE;
@@ -1877,7 +1877,7 @@ display_height_changed_cb(GtkWidget *widget, signal_user_data_t *ud)
        ghb_check_dependency(ud, widget, NULL);
        ghb_clear_presets_selection(ud);
        ghb_live_reset(ud);
-       if (GTK_WIDGET_SENSITIVE(widget))
+       if (gtk_widget_is_sensitive(widget))
                ghb_set_scale (ud, GHB_PIC_KEEP_DISPLAY_HEIGHT);
 
        update_preview = TRUE;
@@ -1891,7 +1891,7 @@ par_changed_cb(GtkWidget *widget, signal_user_data_t *ud)
        ghb_check_dependency(ud, widget, NULL);
        ghb_clear_presets_selection(ud);
        ghb_live_reset(ud);
-       if (GTK_WIDGET_SENSITIVE(widget))
+       if (gtk_widget_is_sensitive(widget))
                ghb_set_scale (ud, GHB_PIC_KEEP_PAR);
 
        update_preview = TRUE;
@@ -1905,7 +1905,7 @@ scale_changed_cb(GtkWidget *widget, signal_user_data_t *ud)
        ghb_check_dependency(ud, widget, NULL);
        ghb_clear_presets_selection(ud);
        ghb_live_reset(ud);
-       if (GTK_WIDGET_SENSITIVE(widget))
+       if (gtk_widget_is_sensitive(widget))
                ghb_set_scale (ud, 0);
        update_preview = TRUE;
        
@@ -1946,7 +1946,7 @@ show_crop_changed_cb(GtkWidget *widget, signal_user_data_t *ud)
        ghb_widget_to_setting(ud->settings, widget);
        ghb_check_dependency(ud, widget, NULL);
        ghb_live_reset(ud);
-       if (GTK_WIDGET_SENSITIVE(widget))
+       if (gtk_widget_is_sensitive(widget))
                ghb_set_scale (ud, 0);
        update_preview = TRUE;
 }
@@ -1962,7 +1962,7 @@ generic_entry_changed_cb(GtkEntry *entry, signal_user_data_t *ud)
        // I don't want to process upon every keystroke, so I prevent processing
        // while the widget has focus.
        g_debug("generic_entry_changed_cb ()");
-       if (!GTK_WIDGET_HAS_FOCUS((GtkWidget*)entry))
+       if (!gtk_widget_has_focus((GtkWidget*)entry))
        {
                ghb_widget_to_setting(ud->settings, (GtkWidget*)entry);
        }
index 0da8b3c8b2a44cb6665e3665cb1a40236c5f3aba..6a3a0d26d4f896153b8467d1334a60bac31eed60 100644 (file)
@@ -1666,7 +1666,7 @@ ghb_cell_renderer_text_render (GtkCellRenderer      *cell,
     }
   else if ((flags & GTK_CELL_RENDERER_SELECTED) == GTK_CELL_RENDERER_SELECTED)
     {
-      if (GTK_WIDGET_HAS_FOCUS (widget))
+      if (gtk_widget_has_focus (widget))
        state = GTK_STATE_SELECTED;
       else
        state = GTK_STATE_ACTIVE;
@@ -1787,7 +1787,7 @@ popdown_timeout (gpointer data)
 
   priv->entry_menu_popdown_timeout = 0;
 
-  if (!GTK_WIDGET_HAS_FOCUS (priv->entry))
+  if (!gtk_widget_has_focus (priv->entry))
     ghb_cell_renderer_text_editing_done (GTK_CELL_EDITABLE (priv->entry), data);
 
   return FALSE;
index 06d2eb90944874f86c70d46babdf27e07b4ca2c6..d7602f76863fa50fb3f195d8e98eb14142f191c9 100644 (file)
@@ -115,7 +115,7 @@ x264_entry_changed_cb(GtkWidget *widget, signal_user_data_t *ud)
                options = ghb_settings_get_string(ud->settings, "x264Option");
                ignore_options_update = TRUE;
                ghb_x264_parse_options(ud, options);
-               if (!GTK_WIDGET_HAS_FOCUS(textview))
+               if (!gtk_widget_has_focus(textview))
                {
                        gchar *sopts;