[gimp/gtk3-port: 60/226] modules: s/GtkObject/GtkAdjustment/



commit e5fb40ecbd98034050c6825b7358265b045387a6
Author: Michael Natterer <mitch gimp org>
Date:   Wed Oct 20 12:17:06 2010 +0200

    modules: s/GtkObject/GtkAdjustment/

 modules/color-selector-cmyk-lcms.c |   27 ++++++++++++---------------
 modules/color-selector-cmyk.c      |   10 +++++-----
 modules/color-selector-water.c     |    4 ++--
 3 files changed, 19 insertions(+), 22 deletions(-)
---
diff --git a/modules/color-selector-cmyk-lcms.c b/modules/color-selector-cmyk-lcms.c
index 20eb3f9..56891ea 100644
--- a/modules/color-selector-cmyk-lcms.c
+++ b/modules/color-selector-cmyk-lcms.c
@@ -133,7 +133,6 @@ static void
 colorsel_cmyk_init (ColorselCmyk *module)
 {
   GtkWidget *table;
-  GtkObject *adj;
   gint       i;
 
   static const gchar * const cmyk_labels[] =
@@ -172,22 +171,20 @@ colorsel_cmyk_init (ColorselCmyk *module)
 
   for (i = 0; i < 4; i++)
     {
-      adj = gimp_scale_entry_new (GTK_TABLE (table), 1, i,
-                                  gettext (cmyk_labels[i]),
-                                  -1, -1,
-                                  0.0,
-                                  0.0, 100.0,
-                                  1.0, 10.0,
-                                  0,
-                                  TRUE, 0.0, 0.0,
-                                  gettext (cmyk_tips[i]),
-                                  NULL);
-
-      g_signal_connect (adj, "value-changed",
+      module->adj[i] = gimp_scale_entry_new (GTK_TABLE (table), 1, i,
+                                             gettext (cmyk_labels[i]),
+                                             -1, -1,
+                                             0.0,
+                                             0.0, 100.0,
+                                             1.0, 10.0,
+                                             0,
+                                             TRUE, 0.0, 0.0,
+                                             gettext (cmyk_tips[i]),
+                                             NULL);
+
+      g_signal_connect (module->adj[i], "value-changed",
                         G_CALLBACK (colorsel_cmyk_adj_update),
                         module);
-
-      module->adj[i] = GTK_ADJUSTMENT (adj);
     }
 
   module->name_label = gtk_label_new (NULL);
diff --git a/modules/color-selector-cmyk.c b/modules/color-selector-cmyk.c
index 3e55d10..87b96a7 100644
--- a/modules/color-selector-cmyk.c
+++ b/modules/color-selector-cmyk.c
@@ -113,11 +113,11 @@ colorsel_cmyk_class_finalize (ColorselCmykClass *klass)
 static void
 colorsel_cmyk_init (ColorselCmyk *module)
 {
-  GtkWidget *table;
-  GtkWidget *label;
-  GtkWidget *spinbutton;
-  GtkObject *adj;
-  gint       i;
+  GtkWidget     *table;
+  GtkWidget     *label;
+  GtkWidget     *spinbutton;
+  GtkAdjustment *adj;
+  gint           i;
 
   static const gchar * const cmyk_labels[] =
   {
diff --git a/modules/color-selector-water.c b/modules/color-selector-water.c
index ecc304c..b5236ea 100644
--- a/modules/color-selector-water.c
+++ b/modules/color-selector-water.c
@@ -174,8 +174,8 @@ colorsel_water_init (ColorselWater *water)
   gtk_widget_set_extension_events (area, GDK_EXTENSION_EVENTS_ALL);
   gtk_widget_grab_focus (area);
 
-  adj = GTK_ADJUSTMENT (gtk_adjustment_new (200.0 - water->pressure_adjust * 100.0,
-                                            0.0, 200.0, 1.0, 1.0, 0.0));
+  adj = gtk_adjustment_new (200.0 - water->pressure_adjust * 100.0,
+                            0.0, 200.0, 1.0, 1.0, 0.0);
   g_signal_connect (adj, "value-changed",
                     G_CALLBACK (pressure_adjust_update),
                     water);


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