Deprecate flag macros for toplevel, state, no window and composite child
Deprecate widget flag macros GTK_WIDGET_STATE, GTK_WIDGET_SAVED_STATE, GTK_WIDGET_FLAGS, GTK_WIDGET_TOPLEVEL, GTK_WIDGET_NO_WINDOW and GTK_WIDGET_COMPOSITE_CHILD. Also deprecate the type macros GTK_WIDGET_TYPE, GTK_OBJECT_TYPE_NAME and GTK_OBJECT_TYPE which have become redundant. Instances of GTK_WIDGET_TOPLEVEL are replaced with gtk_widget_is_toplevel, GTK_WIDGET_TYPE is replaced with G_OBJECT_TYPE, GTK_WIDGET_COMPOSITE_CHILD is replaced with use of the "composite-child" property and uses of GTK_WIDGET_NO_WINDOW are adjusted to use gtk_widget_get_has_window. Uses of GTK_WIDGET_SAVED_STATE and GTK_WIDGET_FLAGS inside GtkWidget are changed to direct flag usage. Documentation is updated to refer to gtk_widget_set_has_window and gtk_widget_get_has_window. Gail and tests are updated as well. Fixes: https://bugzilla.gnome.org/show_bug.cgi?id=69872
This commit is contained in:
@ -690,7 +690,7 @@ gtk_menu_bar_hierarchy_changed (GtkWidget *widget,
|
||||
if (old_toplevel)
|
||||
remove_from_window (GTK_WINDOW (old_toplevel), menubar);
|
||||
|
||||
if (GTK_WIDGET_TOPLEVEL (toplevel))
|
||||
if (gtk_widget_is_toplevel (toplevel))
|
||||
add_to_window (GTK_WINDOW (toplevel), menubar);
|
||||
}
|
||||
|
||||
@ -708,7 +708,7 @@ _gtk_menu_bar_cycle_focus (GtkMenuBar *menubar,
|
||||
GtkWidget *toplevel = gtk_widget_get_toplevel (GTK_WIDGET (menubar));
|
||||
GtkMenuItem *to_activate = NULL;
|
||||
|
||||
if (GTK_WIDGET_TOPLEVEL (toplevel))
|
||||
if (gtk_widget_is_toplevel (toplevel))
|
||||
{
|
||||
GList *tmp_menubars = get_viewable_menu_bars (GTK_WINDOW (toplevel));
|
||||
GList *menubars;
|
||||
|
||||
Reference in New Issue
Block a user