rpms/gpredict/devel gpredict-0.9.0-gtk.patch,1.1,1.2
Lubomir Rintel
lkundrak at fedoraproject.org
Tue May 4 20:40:44 UTC 2010
Author: lkundrak
Update of /cvs/pkgs/rpms/gpredict/devel
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv7034
Modified Files:
gpredict-0.9.0-gtk.patch
Log Message:
Really adjust for newer GTK
gpredict-0.9.0-gtk.patch:
goocanv8/src/goocanvas.c | 32 ++++++++++++++++----------------
goocanv8/src/goocanvasatk.c | 6 +++---
goocanv8/src/goocanvaswidget.c | 4 ++--
src/gtk-azel-plot.c | 2 +-
src/gtk-polar-plot.c | 2 +-
src/gtk-polar-view.c | 2 +-
src/gtk-sat-map.c | 2 +-
src/gtk-sat-module-popup.c | 2 +-
src/gtk-sky-glance.c | 2 +-
src/main.c | 3 +--
10 files changed, 28 insertions(+), 29 deletions(-)
Index: gpredict-0.9.0-gtk.patch
===================================================================
RCS file: /cvs/pkgs/rpms/gpredict/devel/gpredict-0.9.0-gtk.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- gpredict-0.9.0-gtk.patch 2 Mar 2010 12:10:16 -0000 1.1
+++ gpredict-0.9.0-gtk.patch 4 May 2010 20:40:44 -0000 1.2
@@ -1,17 +1,136 @@
-From bee0bffec9d56647695079f1badf699a2765ac0e Mon Sep 17 00:00:00 2001
+From 8108e7f0e8bc2c9940887ad9705a13ab148ce56b Mon Sep 17 00:00:00 2001
From: Lubomir Rintel <lkundrak at v3.sk>
Date: Tue, 2 Mar 2010 13:01:37 +0100
Subject: [PATCH] Det rid of deprecated gtk macros
---
- goocanv8/src/goocanvas.c | 4 ++--
- goocanv8/src/goocanvasatk.c | 4 ++--
- 2 files changed, 4 insertions(+), 4 deletions(-)
+ goocanv8/src/goocanvas.c | 32 ++++++++++++++++----------------
+ goocanv8/src/goocanvasatk.c | 6 +++---
+ goocanv8/src/goocanvaswidget.c | 4 ++--
+ src/gtk-azel-plot.c | 2 +-
+ src/gtk-polar-plot.c | 2 +-
+ src/gtk-polar-view.c | 2 +-
+ src/gtk-sat-map.c | 2 +-
+ src/gtk-sat-module-popup.c | 2 +-
+ src/gtk-sky-glance.c | 2 +-
+ src/main.c | 2 +-
+ 10 files changed, 28 insertions(+), 28 deletions(-)
diff --git a/goocanv8/src/goocanvas.c b/goocanv8/src/goocanvas.c
-index a415f6a..cff67da 100644
+index a415f6a..fb5078e 100644
--- a/goocanv8/src/goocanvas.c
+++ b/goocanv8/src/goocanvas.c
+@@ -741,7 +741,7 @@ goo_canvas_set_root_item_model (GooCanvas *canvas,
+ goo_canvas_item_set_canvas (canvas->root_item, canvas);
+ canvas->need_update = TRUE;
+
+- if (GTK_WIDGET_REALIZED (canvas))
++ if (gtk_widget_get_realized (GTK_WIDGET (canvas)))
+ goo_canvas_update (canvas);
+
+ gtk_widget_queue_draw (GTK_WIDGET (canvas));
+@@ -797,7 +797,7 @@ goo_canvas_set_root_item (GooCanvas *canvas,
+
+ canvas->need_update = TRUE;
+
+- if (GTK_WIDGET_REALIZED (canvas))
++ if (gtk_widget_get_realized (GTK_WIDGET (canvas)))
+ goo_canvas_update (canvas);
+
+ gtk_widget_queue_draw (GTK_WIDGET (canvas));
+@@ -1154,9 +1154,9 @@ goo_canvas_map (GtkWidget *widget)
+ GooCanvasWidget *witem = tmp_list->data;
+ tmp_list = tmp_list->next;
+
+- if (witem->widget && GTK_WIDGET_VISIBLE (witem->widget))
++ if (witem->widget && gtk_widget_get_visible (GTK_WIDGET (witem->widget)))
+ {
+- if (!GTK_WIDGET_MAPPED (witem->widget))
++ if (!gtk_widget_get_mapped (GTK_WIDGET (witem->widget)))
+ gtk_widget_map (witem->widget);
+ }
+ }
+@@ -1173,7 +1173,7 @@ goo_canvas_style_set (GtkWidget *widget,
+ if (GTK_WIDGET_CLASS (goo_canvas_parent_class)->style_set)
+ GTK_WIDGET_CLASS (goo_canvas_parent_class)->style_set (widget, old_style);
+
+- if (GTK_WIDGET_REALIZED (widget))
++ if (gtk_widget_get_realized (GTK_WIDGET (widget)))
+ {
+ gdk_window_set_background (widget->window,
+ &widget->style->base[widget->state]);
+@@ -1381,7 +1381,7 @@ reconfigure_canvas (GooCanvas *canvas,
+
+ canvas->freeze_count--;
+
+- if (GTK_WIDGET_REALIZED (canvas))
++ if (gtk_widget_get_realized (GTK_WIDGET (canvas)))
+ {
+ gdk_window_move_resize (canvas->canvas_window, window_x, window_y,
+ window_width, window_height);
+@@ -1465,7 +1465,7 @@ goo_canvas_size_allocate (GtkWidget *widget,
+
+ widget->allocation = *allocation;
+
+- if (GTK_WIDGET_REALIZED (widget))
++ if (gtk_widget_get_realized (GTK_WIDGET (widget)))
+ {
+ /* We can only allocate our children when we are realized, since we
+ need a window to create a cairo_t which we use for layout. */
+@@ -1497,7 +1497,7 @@ goo_canvas_adjustment_value_changed (GtkAdjustment *adjustment,
+ {
+ AtkObject *accessible;
+
+- if (!canvas->freeze_count && GTK_WIDGET_REALIZED (canvas))
++ if (!canvas->freeze_count && gtk_widget_get_realized (GTK_WIDGET (canvas)))
+ {
+ gdk_window_move (canvas->canvas_window,
+ - canvas->hadjustment->value,
+@@ -1788,7 +1788,7 @@ goo_canvas_set_scale (GooCanvas *canvas,
+ scrolling is unnecessary and really ugly.
+ FIXME: There is a possible issue with keyboard focus/input methods here,
+ since hidden windows can't have the keyboard focus. */
+- if (GTK_WIDGET_MAPPED (canvas))
++ if (gtk_widget_get_mapped (GTK_WIDGET (canvas)))
+ gdk_window_show (canvas->tmp_window);
+
+ canvas->freeze_count++;
+@@ -1808,7 +1808,7 @@ goo_canvas_set_scale (GooCanvas *canvas,
+
+ /* Now hide the temporary window, so the canvas window will get an expose
+ event. */
+- if (GTK_WIDGET_MAPPED (canvas))
++ if (gtk_widget_get_mapped (GTK_WIDGET (canvas)))
+ gdk_window_hide (canvas->tmp_window);
+ }
+
+@@ -1955,7 +1955,7 @@ goo_canvas_request_update (GooCanvas *canvas)
+ canvas->need_update = TRUE;
+
+ /* We have to wait until we are realized. We'll do a full update then. */
+- if (!GTK_WIDGET_REALIZED (canvas))
++ if (!gtk_widget_get_realized (GTK_WIDGET (canvas)))
+ return;
+
+ /* We use a higher priority than the normal GTK+ resize/redraw idle handlers
+@@ -1982,7 +1982,7 @@ goo_canvas_request_redraw (GooCanvas *canvas,
+ {
+ GdkRectangle rect;
+
+- if (!GTK_WIDGET_DRAWABLE (canvas) || (bounds->x1 == bounds->x2))
++ if (!gtk_widget_is_drawable (GTK_WIDGET (canvas)) || (bounds->x1 == bounds->x2))
+ return;
+
+ /* We subtract one from the left & top edges, in case anti-aliasing makes
+@@ -2157,7 +2157,7 @@ propagate_event (GooCanvas *canvas,
+ gboolean stop_emission = FALSE, valid;
+
+ /* Don't emit any events if the canvas is not realized. */
+- if (!GTK_WIDGET_REALIZED (canvas))
++ if (!gtk_widget_get_realized (GTK_WIDGET (canvas)))
+ return FALSE;
+
+ if (item)
@@ -2607,7 +2607,7 @@ goo_canvas_grab_focus (GooCanvas *canvas,
g_return_if_fail (GOO_IS_CANVAS (canvas));
@@ -30,8 +149,17 @@ index a415f6a..cff67da 100644
return FALSE;
/* If a child widget has the focus, try moving the focus within that. */
+@@ -3376,7 +3376,7 @@ goo_canvas_focus (GtkWidget *widget,
+ data.text_direction = gtk_widget_get_direction (widget);
+ data.start_item = NULL;
+
+- if (GTK_WIDGET_HAS_FOCUS (canvas))
++ if (gtk_widget_has_focus (GTK_WIDGET (canvas)))
+ data.start_item = canvas->focused_item;
+ else if (old_focus_child && GOO_IS_CANVAS_WIDGET (old_focus_child))
+ data.start_item = g_object_get_data (G_OBJECT (old_focus_child),
diff --git a/goocanv8/src/goocanvasatk.c b/goocanv8/src/goocanvasatk.c
-index f32bb64..615a54a 100644
+index f32bb64..e843bb8 100644
--- a/goocanv8/src/goocanvasatk.c
+++ b/goocanv8/src/goocanvasatk.c
@@ -217,7 +217,7 @@ goo_canvas_item_accessible_grab_focus (AtkComponent *component)
@@ -43,7 +171,7 @@ index f32bb64..615a54a 100644
gtk_window_present (GTK_WINDOW (toplevel));
return TRUE;
-@@ -409,7 +409,7 @@ goo_canvas_item_accessible_ref_state_set (AtkObject *accessible)
+@@ -409,11 +409,11 @@ goo_canvas_item_accessible_ref_state_set (AtkObject *accessible)
g_object_get (item, "can-focus", &can_focus, NULL);
@@ -52,6 +180,124 @@ index f32bb64..615a54a 100644
{
atk_state_set_add_state (state_set, ATK_STATE_FOCUSABLE);
+- if (GTK_WIDGET_HAS_FOCUS (canvas)
++ if (gtk_widget_has_focus (GTK_WIDGET (canvas))
+ && canvas->focused_item == item)
+ atk_state_set_add_state (state_set, ATK_STATE_FOCUSED);
+ }
+diff --git a/goocanv8/src/goocanvaswidget.c b/goocanv8/src/goocanvaswidget.c
+index 974892f..62053d7 100644
+--- a/goocanv8/src/goocanvaswidget.c
++++ b/goocanv8/src/goocanvaswidget.c
+@@ -180,7 +180,7 @@ goo_canvas_widget_set_widget (GooCanvasWidget *witem,
+
+ if (simple->canvas)
+ {
+- if (GTK_WIDGET_REALIZED (simple->canvas))
++ if (gtk_widget_get_realized (GTK_WIDGET (simple->canvas)))
+ gtk_widget_set_parent_window (widget,
+ simple->canvas->canvas_window);
+
+@@ -309,7 +309,7 @@ goo_canvas_widget_set_canvas (GooCanvasItem *item,
+
+ if (witem->widget)
+ {
+- if (GTK_WIDGET_REALIZED (simple->canvas))
++ if (gtk_widget_get_realized (GTK_WIDGET (simple->canvas)))
+ gtk_widget_set_parent_window (witem->widget,
+ simple->canvas->canvas_window);
+
+diff --git a/src/gtk-azel-plot.c b/src/gtk-azel-plot.c
+index 8ab22ee..cfe1f68 100644
+--- a/src/gtk-azel-plot.c
++++ b/src/gtk-azel-plot.c
+@@ -459,7 +459,7 @@ size_allocate_cb (GtkWidget *widget, GtkAllocation *allocation, gpointer data)
+ pass_detail_t *detail;
+
+
+- if (GTK_WIDGET_REALIZED (widget)) {
++ if (gtk_widget_get_realized (GTK_WIDGET (widget))) {
+
+ /* get graph dimensions */
+ polv = GTK_AZEL_PLOT (data);
+diff --git a/src/gtk-polar-plot.c b/src/gtk-polar-plot.c
+index 7aad089..1d5d302 100644
+--- a/src/gtk-polar-plot.c
++++ b/src/gtk-polar-plot.c
+@@ -429,7 +429,7 @@ size_allocate_cb (GtkWidget *widget, GtkAllocation *allocation, gpointer data)
+ GtkAnchorType anch = GTK_ANCHOR_CENTER;
+
+
+- if (GTK_WIDGET_REALIZED (widget)) {
++ if (gtk_widget_get_realized (GTK_WIDGET (widget))) {
+
+ /* get graph dimensions */
+ polv = GTK_POLAR_PLOT (data);
+diff --git a/src/gtk-polar-view.c b/src/gtk-polar-view.c
+index 3940e0d..4ec1de6 100644
+--- a/src/gtk-polar-view.c
++++ b/src/gtk-polar-view.c
+@@ -510,7 +510,7 @@ size_allocate_cb (GtkWidget *widget, GtkAllocation *allocation, gpointer data)
+ GtkAnchorType anch = GTK_ANCHOR_CENTER;
+
+
+- if (GTK_WIDGET_REALIZED (widget)) {
++ if (gtk_widget_get_realized (GTK_WIDGET (widget))) {
+
+ /* get graph dimensions */
+ polv = GTK_POLAR_VIEW (data);
+diff --git a/src/gtk-sat-map.c b/src/gtk-sat-map.c
+index 709ebfe..f62d227 100644
+--- a/src/gtk-sat-map.c
++++ b/src/gtk-sat-map.c
+@@ -475,7 +475,7 @@ update_map_size (GtkSatMap *satmap)
+ gfloat ratio; /* ratio between map width and height */
+ gfloat size; /* size = min (alloc.w, ratio*alloc.h) */
+
+- if (GTK_WIDGET_REALIZED (satmap)) {
++ if (gtk_widget_get_realized (GTK_WIDGET (satmap))) {
+ /* get graph dimensions */
+ allocation.width = GTK_WIDGET (satmap)->allocation.width;
+ allocation.height = GTK_WIDGET (satmap)->allocation.height;
+diff --git a/src/gtk-sat-module-popup.c b/src/gtk-sat-module-popup.c
+index 00ea096..a497954 100644
+--- a/src/gtk-sat-module-popup.c
++++ b/src/gtk-sat-module-popup.c
+@@ -982,7 +982,7 @@ module_window_config_cb (GtkWidget *widget, GdkEventConfigure *event, gpointer d
+
+
+ /* data is only useful when window is visible */
+- if (GTK_WIDGET_VISIBLE (widget))
++ if (gtk_widget_get_visible (GTK_WIDGET (widget)))
+ gtk_window_get_position (GTK_WINDOW (widget), &x, &y);
+ else
+ return FALSE; /* carry on normally */
+diff --git a/src/gtk-sky-glance.c b/src/gtk-sky-glance.c
+index 9e64b88..1755570 100644
+--- a/src/gtk-sky-glance.c
++++ b/src/gtk-sky-glance.c
+@@ -412,7 +412,7 @@ size_allocate_cb (GtkWidget *widget, GtkAllocation *allocation, gpointer data)
+ gdouble x,y,w,h;
+
+
+- if (GTK_WIDGET_REALIZED (widget)) {
++ if (gtk_widget_get_realized (GTK_WIDGET (widget))) {
+
+ /* get graph dimensions */
+ skg = GTK_SKY_GLANCE (data);
+diff --git a/src/main.c b/src/main.c
+index 37a35e0..f518a79 100644
+--- a/src/main.c
++++ b/src/main.c
+@@ -318,7 +318,7 @@ gpredict_app_config (GtkWidget *widget, GdkEventConfigure *event, gpointer dat
+
+
+ /* data is only useful when window is visible */
+- if (GTK_WIDGET_VISIBLE (widget))
++ if (gtk_widget_get_visible (GTK_WIDGET (widget)))
+ gtk_window_get_position (GTK_WINDOW (widget), &x, &y);
+ else
+ return FALSE; /* carry on normally */
--
-1.7.0
+1.7.0.1
More information about the scm-commits
mailing list