diff options
47 files changed, 55 insertions, 52 deletions
diff --git a/demos/gtk-demo/offscreen_window.c b/demos/gtk-demo/offscreen_window.c index b6c741bddb..6ff212f5b0 100644 --- a/demos/gtk-demo/offscreen_window.c +++ b/demos/gtk-demo/offscreen_window.c @@ -229,7 +229,7 @@ gtk_rotated_bin_realize (GtkWidget *widget) gint border_width; GtkRequisition child_requisition; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); border_width = GTK_CONTAINER (widget)->border_width; diff --git a/demos/gtk-demo/offscreen_window2.c b/demos/gtk-demo/offscreen_window2.c index 8f1089406a..3ee3630d03 100644 --- a/demos/gtk-demo/offscreen_window2.c +++ b/demos/gtk-demo/offscreen_window2.c @@ -167,7 +167,7 @@ gtk_mirror_bin_realize (GtkWidget *widget) gint border_width; GtkRequisition child_requisition; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); border_width = GTK_CONTAINER (widget)->border_width; diff --git a/docs/tutorial/gtk-tut.sgml b/docs/tutorial/gtk-tut.sgml index c92a550f9e..3eee1bd31c 100755 --- a/docs/tutorial/gtk-tut.sgml +++ b/docs/tutorial/gtk-tut.sgml @@ -11925,7 +11925,7 @@ gtk_dial_realize (GtkWidget *widget) g_return_if_fail (widget != NULL); g_return_if_fail (GTK_IS_DIAL (widget)); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); dial = GTK_DIAL (widget); attributes.x = widget->allocation.x; @@ -15113,7 +15113,7 @@ gtk_dial_realize (GtkWidget *widget) g_return_if_fail (widget != NULL); g_return_if_fail (GTK_IS_DIAL (widget)); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); dial = GTK_DIAL (widget); attributes.x = widget->allocation.x; diff --git a/examples/gtkdial/gtkdial.c b/examples/gtkdial/gtkdial.c index f5d8c3b3ae..31f51c040b 100644 --- a/examples/gtkdial/gtkdial.c +++ b/examples/gtkdial/gtkdial.c @@ -214,7 +214,7 @@ gtk_dial_realize (GtkWidget *widget) g_return_if_fail (widget != NULL); g_return_if_fail (GTK_IS_DIAL (widget)); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); dial = GTK_DIAL (widget); attributes.x = widget->allocation.x; diff --git a/gtk/gtkbutton.c b/gtk/gtkbutton.c index 9f359c4d87..47819ce668 100644 --- a/gtk/gtkbutton.c +++ b/gtk/gtkbutton.c @@ -1175,7 +1175,7 @@ gtk_button_realize (GtkWidget *widget) gint border_width; button = GTK_BUTTON (widget); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); border_width = GTK_CONTAINER (widget)->border_width; diff --git a/gtk/gtkcalendar.c b/gtk/gtkcalendar.c index 3b275656a8..37d55c3c3f 100644 --- a/gtk/gtkcalendar.c +++ b/gtk/gtkcalendar.c @@ -1572,7 +1572,7 @@ gtk_calendar_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.x = widget->allocation.x; attributes.y = widget->allocation.y; diff --git a/gtk/gtkclist.c b/gtk/gtkclist.c index 661bda88f5..08216ae2f7 100644 --- a/gtk/gtkclist.c +++ b/gtk/gtkclist.c @@ -4458,7 +4458,7 @@ gtk_clist_realize (GtkWidget *widget) clist = GTK_CLIST (widget); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); border_width = GTK_CONTAINER (widget)->border_width; diff --git a/gtk/gtkdrawingarea.c b/gtk/gtkdrawingarea.c index 4b4dfdea4c..fa7d8b44b6 100644 --- a/gtk/gtkdrawingarea.c +++ b/gtk/gtkdrawingarea.c @@ -85,7 +85,7 @@ gtk_drawing_area_realize (GtkWidget *widget) } else { - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; diff --git a/gtk/gtkentry.c b/gtk/gtkentry.c index f132753220..c4aeb66c25 100644 --- a/gtk/gtkentry.c +++ b/gtk/gtkentry.c @@ -2753,7 +2753,7 @@ gtk_entry_realize (GtkWidget *widget) gint attributes_mask; int i; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); entry = GTK_ENTRY (widget); priv = GTK_ENTRY_GET_PRIVATE (entry); diff --git a/gtk/gtkeventbox.c b/gtk/gtkeventbox.c index 7ac4f38ae4..bb334e154f 100644 --- a/gtk/gtkeventbox.c +++ b/gtk/gtkeventbox.c @@ -372,7 +372,7 @@ gtk_event_box_realize (GtkWidget *widget) GtkEventBoxPrivate *priv; gboolean visible_window; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); border_width = GTK_CONTAINER (widget)->border_width; diff --git a/gtk/gtkexpander.c b/gtk/gtkexpander.c index eb474041f4..df64e54804 100644 --- a/gtk/gtkexpander.c +++ b/gtk/gtkexpander.c @@ -403,7 +403,7 @@ gtk_expander_realize (GtkWidget *widget) gint label_height; priv = GTK_EXPANDER (widget)->priv; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); border_width = GTK_CONTAINER (widget)->border_width; diff --git a/gtk/gtkfixed.c b/gtk/gtkfixed.c index c915bb427a..3106e1f000 100644 --- a/gtk/gtkfixed.c +++ b/gtk/gtkfixed.c @@ -277,7 +277,7 @@ gtk_fixed_realize (GtkWidget *widget) GTK_WIDGET_CLASS (gtk_fixed_parent_class)->realize (widget); else { - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; diff --git a/gtk/gtkhandlebox.c b/gtk/gtkhandlebox.c index 720d7fcc31..b3e12d3124 100644 --- a/gtk/gtkhandlebox.c +++ b/gtk/gtkhandlebox.c @@ -394,7 +394,7 @@ gtk_handle_box_realize (GtkWidget *widget) hb = GTK_HANDLE_BOX (widget); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.x = widget->allocation.x; attributes.y = widget->allocation.y; diff --git a/gtk/gtkhsv.c b/gtk/gtkhsv.c index 704b69e7ed..a9b4bb5ce0 100644 --- a/gtk/gtkhsv.c +++ b/gtk/gtkhsv.c @@ -279,7 +279,7 @@ gtk_hsv_realize (GtkWidget *widget) hsv = GTK_HSV (widget); priv = hsv->priv; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); /* Create window */ diff --git a/gtk/gtkiconview.c b/gtk/gtkiconview.c index 74eaacd4b2..24718bdb59 100644 --- a/gtk/gtkiconview.c +++ b/gtk/gtkiconview.c @@ -1318,7 +1318,7 @@ gtk_icon_view_realize (GtkWidget *widget) icon_view = GTK_ICON_VIEW (widget); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); /* Make the main, clipping window */ attributes.window_type = GDK_WINDOW_CHILD; diff --git a/gtk/gtkinvisible.c b/gtk/gtkinvisible.c index 0ca218dfa9..c24487cb53 100644 --- a/gtk/gtkinvisible.c +++ b/gtk/gtkinvisible.c @@ -218,7 +218,7 @@ gtk_invisible_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); parent = gtk_widget_get_parent_window (widget); if (parent == NULL) diff --git a/gtk/gtkitem.c b/gtk/gtkitem.c index cc5e3df0b4..b21c1e5fc1 100644 --- a/gtk/gtkitem.c +++ b/gtk/gtkitem.c @@ -125,7 +125,7 @@ gtk_item_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.x = widget->allocation.x; attributes.y = widget->allocation.y; diff --git a/gtk/gtklayout.c b/gtk/gtklayout.c index 6f74e644fa..be7917bd37 100644 --- a/gtk/gtklayout.c +++ b/gtk/gtklayout.c @@ -847,7 +847,7 @@ gtk_layout_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (layout, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; diff --git a/gtk/gtklist.c b/gtk/gtklist.c index 11a643d25b..29a0c637d9 100644 --- a/gtk/gtklist.c +++ b/gtk/gtklist.c @@ -451,7 +451,7 @@ gtk_list_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; diff --git a/gtk/gtklistitem.c b/gtk/gtklistitem.c index 68c9e92da6..d01346259c 100644 --- a/gtk/gtklistitem.c +++ b/gtk/gtklistitem.c @@ -431,7 +431,7 @@ gtk_list_item_realize (GtkWidget *widget) g_return_if_fail (GTK_IS_LIST_ITEM (widget)); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.x = widget->allocation.x; attributes.y = widget->allocation.y; diff --git a/gtk/gtkmenu.c b/gtk/gtkmenu.c index 083c1334be..cbc95adfc8 100644 --- a/gtk/gtkmenu.c +++ b/gtk/gtkmenu.c @@ -2263,7 +2263,7 @@ gtk_menu_realize (GtkWidget *widget) menu = GTK_MENU (widget); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; diff --git a/gtk/gtkmenuitem.c b/gtk/gtkmenuitem.c index 4b26231441..3d4749976e 100644 --- a/gtk/gtkmenuitem.c +++ b/gtk/gtkmenuitem.c @@ -1129,7 +1129,7 @@ gtk_menu_item_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); widget->window = gtk_widget_get_parent_window (widget); g_object_ref (widget->window); diff --git a/gtk/gtkmenushell.c b/gtk/gtkmenushell.c index 4a86b20376..4788590700 100644 --- a/gtk/gtkmenushell.c +++ b/gtk/gtkmenushell.c @@ -513,7 +513,7 @@ gtk_menu_shell_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.x = widget->allocation.x; attributes.y = widget->allocation.y; diff --git a/gtk/gtkmisc.c b/gtk/gtkmisc.c index e625f38b13..93d8421837 100644 --- a/gtk/gtkmisc.c +++ b/gtk/gtkmisc.c @@ -308,7 +308,7 @@ gtk_misc_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); if (!gtk_widget_get_has_window (widget)) { diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c index fb3fa7d901..a8e99db244 100644 --- a/gtk/gtknotebook.c +++ b/gtk/gtknotebook.c @@ -1798,7 +1798,8 @@ gtk_notebook_realize (GtkWidget *widget) GdkRectangle event_window_pos; notebook = GTK_NOTEBOOK (widget); - GTK_WIDGET_SET_FLAGS (notebook, GTK_REALIZED); + + gtk_widget_set_realized (widget, TRUE); gtk_notebook_get_event_window_position (notebook, &event_window_pos); diff --git a/gtk/gtkoffscreenwindow.c b/gtk/gtkoffscreenwindow.c index 78818e47a4..0633a787a3 100644 --- a/gtk/gtkoffscreenwindow.c +++ b/gtk/gtkoffscreenwindow.c @@ -125,7 +125,7 @@ gtk_offscreen_window_realize (GtkWidget *widget) bin = GTK_BIN (widget); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); border_width = gtk_container_get_border_width (GTK_CONTAINER (widget)); diff --git a/gtk/gtkpaned.c b/gtk/gtkpaned.c index 6fa46888c4..1e98163798 100644 --- a/gtk/gtkpaned.c +++ b/gtk/gtkpaned.c @@ -978,7 +978,7 @@ gtk_paned_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); paned = GTK_PANED (widget); widget->window = gtk_widget_get_parent_window (widget); diff --git a/gtk/gtkpathbar.c b/gtk/gtkpathbar.c index 69d3b62c64..48eec632d2 100644 --- a/gtk/gtkpathbar.c +++ b/gtk/gtkpathbar.c @@ -408,7 +408,7 @@ gtk_path_bar_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); path_bar = GTK_PATH_BAR (widget); widget->window = gtk_widget_get_parent_window (widget); diff --git a/gtk/gtkplug.c b/gtk/gtkplug.c index 45352f250f..8de5b2f097 100644 --- a/gtk/gtkplug.c +++ b/gtk/gtkplug.c @@ -607,7 +607,7 @@ gtk_plug_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; /* XXX GDK_WINDOW_PLUG ? */ attributes.title = window->title; diff --git a/gtk/gtkpreview.c b/gtk/gtkpreview.c index fa74ebdff5..458fed4efe 100644 --- a/gtk/gtkpreview.c +++ b/gtk/gtkpreview.c @@ -420,7 +420,7 @@ gtk_preview_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; diff --git a/gtk/gtkprogress.c b/gtk/gtkprogress.c index ef062bb689..8f46de45da 100644 --- a/gtk/gtkprogress.c +++ b/gtk/gtkprogress.c @@ -212,7 +212,7 @@ gtk_progress_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; diff --git a/gtk/gtkrange.c b/gtk/gtkrange.c index 85cb85f681..ab295b9f39 100644 --- a/gtk/gtkrange.c +++ b/gtk/gtkrange.c @@ -1495,7 +1495,7 @@ gtk_range_realize (GtkWidget *widget) gtk_range_calc_layout (range, range->adjustment->value); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); widget->window = gtk_widget_get_parent_window (widget); g_object_ref (widget->window); diff --git a/gtk/gtkruler.c b/gtk/gtkruler.c index ae86b0b498..d066775df9 100644 --- a/gtk/gtkruler.c +++ b/gtk/gtkruler.c @@ -441,7 +441,8 @@ gtk_ruler_realize (GtkWidget *widget) gint attributes_mask; ruler = GTK_RULER (widget); - GTK_WIDGET_SET_FLAGS (ruler, GTK_REALIZED); + + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; diff --git a/gtk/gtksocket.c b/gtk/gtksocket.c index fc15775a91..847ee9ff01 100644 --- a/gtk/gtksocket.c +++ b/gtk/gtksocket.c @@ -326,7 +326,7 @@ gtk_socket_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; @@ -390,7 +390,7 @@ gtk_socket_unrealize (GtkWidget *widget) { GtkSocket *socket = GTK_SOCKET (widget); - GTK_WIDGET_UNSET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, FALSE); if (socket->plug_widget) { diff --git a/gtk/gtktext.c b/gtk/gtktext.c index 543bd2ca53..5fdbb38d99 100644 --- a/gtk/gtktext.c +++ b/gtk/gtktext.c @@ -1239,7 +1239,7 @@ gtk_text_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (text, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; diff --git a/gtk/gtktextview.c b/gtk/gtktextview.c index 6f62590055..0504f59dbd 100644 --- a/gtk/gtktextview.c +++ b/gtk/gtktextview.c @@ -3827,7 +3827,8 @@ gtk_text_view_realize (GtkWidget *widget) GSList *tmp_list; text_view = GTK_TEXT_VIEW (widget); - GTK_WIDGET_SET_FLAGS (text_view, GTK_REALIZED); + + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; diff --git a/gtk/gtktoolbar.c b/gtk/gtktoolbar.c index 36b0e9a2a6..8f065a7f8a 100644 --- a/gtk/gtktoolbar.c +++ b/gtk/gtktoolbar.c @@ -813,7 +813,7 @@ gtk_toolbar_realize (GtkWidget *widget) gint attributes_mask; gint border_width; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); border_width = GTK_CONTAINER (widget)->border_width; diff --git a/gtk/gtktoolitem.c b/gtk/gtktoolitem.c index da2e45f1f4..606ce1e847 100644 --- a/gtk/gtktoolitem.c +++ b/gtk/gtktoolitem.c @@ -462,7 +462,7 @@ gtk_tool_item_realize (GtkWidget *widget) GtkToolItem *toolitem; toolitem = GTK_TOOL_ITEM (widget); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); widget->window = gtk_widget_get_parent_window (widget); g_object_ref (widget->window); diff --git a/gtk/gtktoolitemgroup.c b/gtk/gtktoolitemgroup.c index 7f1db34e28..ecff531c45 100644 --- a/gtk/gtktoolitemgroup.c +++ b/gtk/gtktoolitemgroup.c @@ -1181,7 +1181,7 @@ gtk_tool_item_group_realize (GtkWidget *widget) gdk_window_set_user_data (widget->window, widget); widget->style = gtk_style_attach (widget->style, widget->window); gtk_style_set_background (widget->style, widget->window, GTK_STATE_NORMAL); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); gtk_container_forall (GTK_CONTAINER (widget), (GtkCallback) gtk_widget_set_parent_window, diff --git a/gtk/gtktoolpalette.c b/gtk/gtktoolpalette.c index 94ea45247b..e7b94007a7 100644 --- a/gtk/gtktoolpalette.c +++ b/gtk/gtktoolpalette.c @@ -672,7 +672,7 @@ gtk_tool_palette_realize (GtkWidget *widget) gdk_window_set_user_data (widget->window, widget); widget->style = gtk_style_attach (widget->style, widget->window); gtk_style_set_background (widget->style, widget->window, GTK_STATE_NORMAL); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); gtk_container_forall (GTK_CONTAINER (widget), (GtkCallback) gtk_widget_set_parent_window, diff --git a/gtk/gtktree.c b/gtk/gtktree.c index f3e6f7f36d..1ac137a98b 100644 --- a/gtk/gtktree.c +++ b/gtk/gtktree.c @@ -560,7 +560,7 @@ gtk_tree_realize (GtkWidget *widget) g_return_if_fail (GTK_IS_TREE (widget)); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.x = widget->allocation.x; diff --git a/gtk/gtktreeview.c b/gtk/gtktreeview.c index 3b80571570..f11f6f21a8 100644 --- a/gtk/gtktreeview.c +++ b/gtk/gtktreeview.c @@ -1767,7 +1767,7 @@ gtk_tree_view_realize (GtkWidget *widget) GdkWindowAttr attributes; gint attributes_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); /* Make the main, clipping window */ attributes.window_type = GDK_WINDOW_CHILD; diff --git a/gtk/gtkviewport.c b/gtk/gtkviewport.c index e36ae687b6..bfda9f28bf 100644 --- a/gtk/gtkviewport.c +++ b/gtk/gtkviewport.c @@ -588,7 +588,7 @@ gtk_viewport_realize (GtkWidget *widget) gint attributes_mask; gint event_mask; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.x = widget->allocation.x + border_width; attributes.y = widget->allocation.y + border_width; diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c index c0549c2394..275f06e341 100644 --- a/gtk/gtkwidget.c +++ b/gtk/gtkwidget.c @@ -5989,9 +5989,9 @@ gtk_widget_set_realized (GtkWidget *widget, g_return_if_fail (GTK_IS_WIDGET (widget)); if (realized) - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + GTK_OBJECT_FLAGS (widget) |= GTK_REALIZED; else - GTK_WIDGET_UNSET_FLAGS (widget, GTK_REALIZED); + GTK_OBJECT_FLAGS (widget) &= ~(GTK_REALIZED); } /** @@ -8793,7 +8793,7 @@ gtk_widget_real_realize (GtkWidget *widget) { g_assert (!gtk_widget_get_has_window (widget)); - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); if (widget->parent) { widget->window = gtk_widget_get_parent_window (widget); @@ -8847,7 +8847,7 @@ gtk_widget_real_unrealize (GtkWidget *widget) gtk_selection_remove_all (widget); - GTK_WIDGET_UNSET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, FALSE); } static void diff --git a/gtk/gtkwin32embedwidget.c b/gtk/gtkwin32embedwidget.c index 7604923bb3..e710a8bfe2 100644 --- a/gtk/gtkwin32embedwidget.c +++ b/gtk/gtkwin32embedwidget.c @@ -200,7 +200,7 @@ gtk_win32_embed_widget_realize (GtkWidget *widget) g_return_if_fail (!gtk_widget_get_realized (widget)); } - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); attributes.window_type = GDK_WINDOW_CHILD; attributes.title = window->title; diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c index 8d05b77b1b..577f672c55 100644 --- a/gtk/gtkwindow.c +++ b/gtk/gtkwindow.c @@ -4742,7 +4742,7 @@ gtk_window_realize (GtkWidget *widget) g_return_if_fail (!gtk_widget_get_realized (widget)); } - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); switch (window->type) { diff --git a/tests/gtkoffscreenbox.c b/tests/gtkoffscreenbox.c index 760810ceb8..b6caa14c8b 100644 --- a/tests/gtkoffscreenbox.c +++ b/tests/gtkoffscreenbox.c @@ -238,7 +238,7 @@ gtk_offscreen_box_realize (GtkWidget *widget) GtkRequisition child_requisition; int start_y = 0; - GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED); + gtk_widget_set_realized (widget, TRUE); border_width = GTK_CONTAINER (widget)->border_width; |