Dash:
[t2-trunk.git] / package / gnome / gdmap / 03-gtk-widget-macros.patch
blob34a92257077d96b45245459b1df8cde2d19bdf0b
1 Description: Replace deprecated GTK macros with appropriate function
2 Author: Luca Falavigna <dktrkranz@debian.org>
3 Author: Stephen Kitt <steve@sk2.org>
5 --- gdmap.orig/src/gui_support.c
6 +++ gdmap/src/gui_support.c
7 @@ -85,7 +85,7 @@
8 const char* text;
10 (void)event;
11 - if (GTK_WIDGET_SENSITIVE(label)) {
12 + if (gtk_widget_get_sensitive(label)) {
13 char* temp;
15 text = g_object_get_data(G_OBJECT(label), "label");
16 @@ -129,7 +129,7 @@
17 void ui_event_label_set_sensitive(GtkWidget* ebox, gboolean set) {
18 gpointer callback = g_object_get_data(G_OBJECT(ebox), "callback");
19 GtkWidget* child = GTK_BIN(ebox)->child;
20 - if (GTK_WIDGET_SENSITIVE(child) == set) return;
21 + if (gtk_widget_get_sensitive(child) == set) return;
23 if (set && !callback) return;
24 gtk_widget_set_sensitive(child, set);
25 @@ -164,7 +164,7 @@
26 // GDK_FOCUS_CHANGE_MASK |
27 GDK_ENTER_NOTIFY_MASK |
28 GDK_LEAVE_NOTIFY_MASK);
29 - GTK_WIDGET_SET_FLAGS(ebox, GTK_CAN_FOCUS);
30 + gtk_widget_set_can_focus(ebox, TRUE);
32 gtk_widget_show(ebox);