widget: Use a real offset in gtk_widget_class_automate_child

Using an offset from the struct means you can have children in
both the public and private (via G_PRIVATE_OFFSET) parts of the
instance. It also matches the new private macros nicer.

https://bugzilla.gnome.org/show_bug.cgi?id=702563

Signed-off-by: Emmanuele Bassi <ebassi@gnome.org>
This commit is contained in:
Alexander Larsson 2013-07-26 08:41:09 -04:00 committed by Matthias Clasen
parent 45d2f677be
commit a8e84545d1
37 changed files with 283 additions and 288 deletions

View File

@ -253,19 +253,19 @@ gtk_message_row_class_init (GtkMessageRowClass *klass)
GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);
gtk_widget_class_set_template_from_resource (widget_class, "/listbox/listbox.ui");
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, content_label);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, source_name);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, source_nick);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, short_time_label);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, detailed_time_label);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, extra_buttons_box);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, details_revealer);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, avatar_image);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, resent_box);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, resent_by_button);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, n_reshares_label);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, n_favorites_label);
gtk_widget_class_bind_child(widget_class, GtkMessageRowPrivate, expand_button);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, content_label);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, source_name);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, source_nick);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, short_time_label);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, detailed_time_label);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, extra_buttons_box);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, details_revealer);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, avatar_image);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, resent_box);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, resent_by_button);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, n_reshares_label);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, n_favorites_label);
gtk_widget_class_bind_child (widget_class, GtkMessageRow, expand_button);
gtk_widget_class_bind_callback (widget_class, expand_clicked);
gtk_widget_class_bind_callback (widget_class, reshare_clicked);
gtk_widget_class_bind_callback (widget_class, favorite_clicked);

View File

@ -32,7 +32,7 @@ example_app_window_class_init (ExampleAppWindowClass *class)
{
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/window.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, stack);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, stack);
}
ExampleAppWindow *

View File

@ -32,7 +32,7 @@ example_app_window_class_init (ExampleAppWindowClass *class)
{
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/window.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, stack);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, stack);
}
ExampleAppWindow *

View File

@ -57,7 +57,7 @@ example_app_window_class_init (ExampleAppWindowClass *class)
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/window.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, stack);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, stack);
}
ExampleAppWindow *

View File

@ -59,9 +59,9 @@ example_app_prefs_class_init (ExampleAppPrefsClass *class)
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/prefs.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, font);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, transition);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, close);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, font);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, transition);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, close);
}
ExampleAppPrefs *

View File

@ -54,7 +54,7 @@ example_app_window_class_init (ExampleAppWindowClass *class)
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/window.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, stack);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, stack);
}
ExampleAppWindow *

View File

@ -63,9 +63,9 @@ example_app_prefs_class_init (ExampleAppPrefsClass *class)
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/prefs.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, font);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, transition);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, close);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, font);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, transition);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, close);
}
ExampleAppPrefs *

View File

@ -116,10 +116,10 @@ example_app_window_class_init (ExampleAppWindowClass *class)
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/window.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, stack);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, search);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, searchbar);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, searchentry);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, stack);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, search);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, searchbar);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, searchentry);
}
ExampleAppWindow *

View File

@ -63,9 +63,9 @@ example_app_prefs_class_init (ExampleAppPrefsClass *class)
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/prefs.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, font);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, transition);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, close);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, font);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, transition);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, close);
}
ExampleAppPrefs *

View File

@ -219,13 +219,13 @@ example_app_window_class_init (ExampleAppWindowClass *class)
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/window.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, stack);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, search);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, searchbar);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, searchentry);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, gears);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, words);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, sidebar);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, stack);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, search);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, searchbar);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, searchentry);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, gears);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, words);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, sidebar);
}
ExampleAppWindow *

View File

@ -63,9 +63,9 @@ example_app_prefs_class_init (ExampleAppPrefsClass *class)
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/prefs.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, font);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, transition);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefsPrivate, close);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, font);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, transition);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppPrefs, close);
}
ExampleAppPrefs *

View File

@ -265,15 +265,15 @@ example_app_window_class_init (ExampleAppWindowClass *class)
gtk_widget_class_set_template_from_resource (GTK_WIDGET_CLASS (class),
"/org/gtk/exampleapp/window.ui");
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, stack);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, search);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, searchbar);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, searchentry);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, gears);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, words);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, sidebar);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, lines);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindowPrivate, lines_label);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, stack);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, search);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, searchbar);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, searchentry);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, gears);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, words);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, sidebar);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, lines);
gtk_widget_class_bind_child (GTK_WIDGET_CLASS (class), ExampleAppWindow, lines_label);
}
ExampleAppWindow *

View File

@ -557,18 +557,18 @@ gtk_about_dialog_class_init (GtkAboutDialogClass *klass)
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkaboutdialog.ui");
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, notebook);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, logo_image);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, name_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, version_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, comments_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, copyright_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, license_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, website_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, credits_button);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, license_button);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, credits_grid);
gtk_widget_class_bind_child (widget_class, GtkAboutDialogPrivate, license_view);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, notebook);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, logo_image);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, name_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, version_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, comments_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, copyright_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, license_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, website_label);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, credits_button);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, license_button);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, credits_grid);
gtk_widget_class_bind_child (widget_class, GtkAboutDialog, license_view);
gtk_widget_class_bind_callback (widget_class, credits_button_clicked);
gtk_widget_class_bind_callback (widget_class, license_button_clicked);

View File

@ -660,10 +660,10 @@ gtk_app_chooser_dialog_class_init (GtkAppChooserDialogClass *klass)
widget_class = GTK_WIDGET_CLASS (klass);
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkappchooserdialog.ui");
gtk_widget_class_bind_child (widget_class, GtkAppChooserDialogPrivate, label);
gtk_widget_class_bind_child (widget_class, GtkAppChooserDialogPrivate, button);
gtk_widget_class_bind_child (widget_class, GtkAppChooserDialogPrivate, show_more_button);
gtk_widget_class_bind_child (widget_class, GtkAppChooserDialogPrivate, inner_box);
gtk_widget_class_bind_child (widget_class, GtkAppChooserDialog, label);
gtk_widget_class_bind_child (widget_class, GtkAppChooserDialog, button);
gtk_widget_class_bind_child (widget_class, GtkAppChooserDialog, show_more_button);
gtk_widget_class_bind_child (widget_class, GtkAppChooserDialog, inner_box);
gtk_widget_class_bind_callback (widget_class, show_more_button_clicked_cb);
}

View File

@ -1086,11 +1086,11 @@ gtk_app_chooser_widget_class_init (GtkAppChooserWidgetClass *klass)
widget_class = GTK_WIDGET_CLASS (klass);
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkappchooserwidget.ui");
gtk_widget_class_bind_child (widget_class, GtkAppChooserWidgetPrivate, program_list);
gtk_widget_class_bind_child (widget_class, GtkAppChooserWidgetPrivate, program_list_store);
gtk_widget_class_bind_child (widget_class, GtkAppChooserWidgetPrivate, column);
gtk_widget_class_bind_child (widget_class, GtkAppChooserWidgetPrivate, padding_renderer);
gtk_widget_class_bind_child (widget_class, GtkAppChooserWidgetPrivate, secondary_padding);
gtk_widget_class_bind_child (widget_class, GtkAppChooserWidget, program_list);
gtk_widget_class_bind_child (widget_class, GtkAppChooserWidget, program_list_store);
gtk_widget_class_bind_child (widget_class, GtkAppChooserWidget, column);
gtk_widget_class_bind_child (widget_class, GtkAppChooserWidget, padding_renderer);
gtk_widget_class_bind_child (widget_class, GtkAppChooserWidget, secondary_padding);
gtk_widget_class_bind_callback (widget_class, refresh_and_emit_app_selected);
gtk_widget_class_bind_callback (widget_class, program_list_selection_activated);
gtk_widget_class_bind_callback (widget_class, widget_button_press_event_cb);

View File

@ -431,17 +431,17 @@ gtk_assistant_class_init (GtkAssistantClass *class)
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkassistant.ui");
gtk_widget_class_bind_child_internal (widget_class, GtkAssistantPrivate, action_area);
gtk_widget_class_bind_child (widget_class, GtkAssistantPrivate, content);
gtk_widget_class_bind_child (widget_class, GtkAssistantPrivate, cancel);
gtk_widget_class_bind_child (widget_class, GtkAssistantPrivate, forward);
gtk_widget_class_bind_child (widget_class, GtkAssistantPrivate, back);
gtk_widget_class_bind_child (widget_class, GtkAssistantPrivate, apply);
gtk_widget_class_bind_child (widget_class, GtkAssistantPrivate, close);
gtk_widget_class_bind_child (widget_class, GtkAssistantPrivate, last);
gtk_widget_class_bind_child (widget_class, GtkAssistantPrivate, sidebar);
gtk_widget_class_bind_child (widget_class, GtkAssistantPrivate, button_size_group);
gtk_widget_class_bind_child (widget_class, GtkAssistantPrivate, title_size_group);
gtk_widget_class_bind_child_internal (widget_class, GtkAssistant, action_area);
gtk_widget_class_bind_child (widget_class, GtkAssistant, content);
gtk_widget_class_bind_child (widget_class, GtkAssistant, cancel);
gtk_widget_class_bind_child (widget_class, GtkAssistant, forward);
gtk_widget_class_bind_child (widget_class, GtkAssistant, back);
gtk_widget_class_bind_child (widget_class, GtkAssistant, apply);
gtk_widget_class_bind_child (widget_class, GtkAssistant, close);
gtk_widget_class_bind_child (widget_class, GtkAssistant, last);
gtk_widget_class_bind_child (widget_class, GtkAssistant, sidebar);
gtk_widget_class_bind_child (widget_class, GtkAssistant, button_size_group);
gtk_widget_class_bind_child (widget_class, GtkAssistant, title_size_group);
gtk_widget_class_bind_callback (widget_class, assistant_sidebar_draw_cb);
gtk_widget_class_bind_callback (widget_class, assistant_remove_page_cb);

View File

@ -202,9 +202,9 @@ gtk_color_chooser_dialog_class_init (GtkColorChooserDialogClass *class)
*/
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkcolorchooserdialog.ui");
gtk_widget_class_bind_child (widget_class, GtkColorChooserDialogPrivate, chooser);
gtk_widget_class_bind_child (widget_class, GtkColorChooserDialogPrivate, cancel_button);
gtk_widget_class_bind_child (widget_class, GtkColorChooserDialogPrivate, select_button);
gtk_widget_class_bind_child (widget_class, GtkColorChooserDialog, chooser);
gtk_widget_class_bind_child (widget_class, GtkColorChooserDialog, cancel_button);
gtk_widget_class_bind_child (widget_class, GtkColorChooserDialog, select_button);
gtk_widget_class_bind_callback (widget_class, selected_cb);
gtk_widget_class_bind_callback (widget_class, propagate_notify);
gtk_widget_class_bind_callback (widget_class, color_activated_cb);

View File

@ -464,24 +464,24 @@ gtk_color_editor_class_init (GtkColorEditorClass *class)
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkcoloreditor.ui");
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, overlay);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, grid);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, swatch);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, entry);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, h_slider);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, h_popup);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, h_entry);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, a_slider);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, a_popup);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, a_entry);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, sv_plane);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, sv_popup);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, s_entry);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, v_entry);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, h_adj);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, s_adj);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, v_adj);
gtk_widget_class_bind_child (widget_class, GtkColorEditorPrivate, a_adj);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, overlay);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, grid);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, swatch);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, entry);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, h_slider);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, h_popup);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, h_entry);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, a_slider);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, a_popup);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, a_entry);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, sv_plane);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, sv_popup);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, s_entry);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, v_entry);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, h_adj);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, s_adj);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, v_adj);
gtk_widget_class_bind_child (widget_class, GtkColorEditor, a_adj);
gtk_widget_class_bind_callback (widget_class, hsv_changed);
gtk_widget_class_bind_callback (widget_class, popup_draw);

View File

@ -331,8 +331,8 @@ gtk_dialog_class_init (GtkDialogClass *class)
/* Bind class to template
*/
gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/gtkdialog.ui");
gtk_widget_class_bind_child_internal (widget_class, GtkDialogPrivate, vbox);
gtk_widget_class_bind_child_internal (widget_class, GtkDialogPrivate, action_area);
gtk_widget_class_bind_child_internal (widget_class, GtkDialog, vbox);
gtk_widget_class_bind_child_internal (widget_class, GtkDialog, action_area);
gtk_widget_class_bind_callback (widget_class, gtk_dialog_delete_event_handler);
}

View File

@ -472,13 +472,13 @@ gtk_file_chooser_button_class_init (GtkFileChooserButtonClass * class)
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkfilechooserbutton.ui");
gtk_widget_class_bind_child (widget_class, GtkFileChooserButtonPrivate, model);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButtonPrivate, button);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButtonPrivate, image);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButtonPrivate, label);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButtonPrivate, combo_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButtonPrivate, icon_cell);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButtonPrivate, name_cell);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButton, model);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButton, button);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButton, image);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButton, label);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButton, combo_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButton, icon_cell);
gtk_widget_class_bind_child (widget_class, GtkFileChooserButton, name_cell);
gtk_widget_class_bind_callback (widget_class, button_clicked_cb);
gtk_widget_class_bind_callback (widget_class, combo_box_changed_cb);

View File

@ -7466,33 +7466,33 @@ _gtk_file_chooser_default_class_init (GtkFileChooserDefaultClass *class)
/* A *lot* of widgets that we need to handle .... */
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_widgets_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_widgets_hpaned);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_header_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_widgets_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, places_sidebar);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_files_tree_view);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_new_folder_button);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_path_bar_hbox);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_path_bar_size_group);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_path_bar);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_special_mode_icon);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_special_mode_label);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_select_a_folder_info_bar);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_select_a_folder_label);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, browse_select_a_folder_icon);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, filter_combo_hbox);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, filter_combo);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, preview_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, extra_align);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, location_button);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, location_entry_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, location_label);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, list_name_column);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, list_pixbuf_renderer);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, list_name_renderer);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, list_mtime_column);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefaultPrivate, list_size_column);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_widgets_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_widgets_hpaned);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_header_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_widgets_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, places_sidebar);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_files_tree_view);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_new_folder_button);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_path_bar_hbox);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_path_bar_size_group);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_path_bar);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_special_mode_icon);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_special_mode_label);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_select_a_folder_info_bar);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_select_a_folder_label);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, browse_select_a_folder_icon);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, filter_combo_hbox);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, filter_combo);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, preview_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, extra_align);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, location_button);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, location_entry_box);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, location_label);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, list_name_column);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, list_pixbuf_renderer);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, list_name_renderer);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, list_mtime_column);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDefault, list_size_column);
/* And a *lot* of callbacks to bind ... */
gtk_widget_class_bind_callback (widget_class, browse_files_key_press_event_cb);

View File

@ -248,7 +248,7 @@ gtk_file_chooser_dialog_class_init (GtkFileChooserDialogClass *class)
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkfilechooserdialog.ui");
gtk_widget_class_bind_child (widget_class, GtkFileChooserDialogPrivate, widget);
gtk_widget_class_bind_child (widget_class, GtkFileChooserDialog, widget);
gtk_widget_class_bind_callback (widget_class, response_cb);
gtk_widget_class_bind_callback (widget_class, file_chooser_widget_file_activated);
gtk_widget_class_bind_callback (widget_class, file_chooser_widget_default_size_changed);

View File

@ -545,9 +545,9 @@ gtk_font_button_class_init (GtkFontButtonClass *klass)
/* Bind class to template
*/
gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/gtkfontbutton.ui");
gtk_widget_class_bind_child (widget_class, GtkFontButtonPrivate, font_label);
gtk_widget_class_bind_child (widget_class, GtkFontButtonPrivate, size_label);
gtk_widget_class_bind_child (widget_class, GtkFontButtonPrivate, font_size_box);
gtk_widget_class_bind_child (widget_class, GtkFontButton, font_label);
gtk_widget_class_bind_child (widget_class, GtkFontButton, size_label);
gtk_widget_class_bind_child (widget_class, GtkFontButton, font_size_box);
}
static void

View File

@ -136,9 +136,9 @@ gtk_font_chooser_dialog_class_init (GtkFontChooserDialogClass *klass)
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkfontchooserdialog.ui");
gtk_widget_class_bind_child (widget_class, GtkFontChooserDialogPrivate, fontchooser);
gtk_widget_class_bind_child (widget_class, GtkFontChooserDialogPrivate, select_button);
gtk_widget_class_bind_child (widget_class, GtkFontChooserDialogPrivate, cancel_button);
gtk_widget_class_bind_child (widget_class, GtkFontChooserDialog, fontchooser);
gtk_widget_class_bind_child (widget_class, GtkFontChooserDialog, select_button);
gtk_widget_class_bind_child (widget_class, GtkFontChooserDialog, cancel_button);
gtk_widget_class_bind_callback (widget_class, font_activated_cb);
}

View File

@ -478,22 +478,21 @@ gtk_font_chooser_widget_class_init (GtkFontChooserWidgetClass *klass)
_gtk_font_chooser_install_properties (gobject_class);
/* Bind class to template
*/
/* Bind class to template */
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkfontchooserwidget.ui");
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, search_entry);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, family_face_list);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, family_face_column);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, family_face_cell);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, list_scrolled_window);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, list_notebook);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, model);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, filter_model);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, preview);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, size_spin);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidgetPrivate, size_slider);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, search_entry);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, family_face_list);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, family_face_column);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, family_face_cell);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, list_scrolled_window);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, list_notebook);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, model);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, filter_model);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, preview);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, size_spin);
gtk_widget_class_bind_child (widget_class, GtkFontChooserWidget, size_slider);
gtk_widget_class_bind_callback (widget_class, text_changed_cb);
gtk_widget_class_bind_callback (widget_class, cursor_changed_cb);

View File

@ -546,9 +546,9 @@ gtk_info_bar_class_init (GtkInfoBarClass *klass)
/* Bind class to template
*/
gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/gtkinfobar.ui");
gtk_widget_class_bind_child_internal (widget_class, GtkInfoBarPrivate, content_area);
gtk_widget_class_bind_child_internal (widget_class, GtkInfoBarPrivate, action_area);
gtk_widget_class_bind_child_internal (widget_class, GtkInfoBarPrivate, close_button);
gtk_widget_class_bind_child_internal (widget_class, GtkInfoBar, content_area);
gtk_widget_class_bind_child_internal (widget_class, GtkInfoBar, action_area);
gtk_widget_class_bind_child_internal (widget_class, GtkInfoBar, close_button);
}
static void

View File

@ -307,11 +307,11 @@ gtk_lock_button_class_init (GtkLockButtonClass *klass)
/* Bind class to template
*/
gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/gtklockbutton.ui");
gtk_widget_class_bind_child (widget_class, GtkLockButtonPrivate, box);
gtk_widget_class_bind_child (widget_class, GtkLockButtonPrivate, image);
gtk_widget_class_bind_child (widget_class, GtkLockButtonPrivate, label_lock);
gtk_widget_class_bind_child (widget_class, GtkLockButtonPrivate, label_unlock);
gtk_widget_class_bind_child (widget_class, GtkLockButtonPrivate, label_group);
gtk_widget_class_bind_child (widget_class, GtkLockButton, box);
gtk_widget_class_bind_child (widget_class, GtkLockButton, image);
gtk_widget_class_bind_child (widget_class, GtkLockButton, label_lock);
gtk_widget_class_bind_child (widget_class, GtkLockButton, label_unlock);
gtk_widget_class_bind_child (widget_class, GtkLockButton, label_group);
gtk_widget_class_set_accessible_type (widget_class, GTK_TYPE_LOCK_BUTTON_ACCESSIBLE);
}

View File

@ -295,10 +295,10 @@ gtk_message_dialog_class_init (GtkMessageDialogClass *class)
/* Setup Composite data */
gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/gtkmessagedialog.ui");
gtk_widget_class_bind_child (widget_class, GtkMessageDialogPrivate, image);
gtk_widget_class_bind_child (widget_class, GtkMessageDialogPrivate, label);
gtk_widget_class_bind_child (widget_class, GtkMessageDialogPrivate, secondary_label);
gtk_widget_class_bind_child_internal (widget_class, GtkMessageDialogPrivate, message_area);
gtk_widget_class_bind_child (widget_class, GtkMessageDialog, image);
gtk_widget_class_bind_child (widget_class, GtkMessageDialog, label);
gtk_widget_class_bind_child (widget_class, GtkMessageDialog, secondary_label);
gtk_widget_class_bind_child_internal (widget_class, GtkMessageDialog, message_area);
}
static void

View File

@ -162,17 +162,17 @@ gtk_page_setup_unix_dialog_class_init (GtkPageSetupUnixDialogClass *class)
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkpagesetupunixdialog.ui");
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, printer_list);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, page_setup_list);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, custom_paper_list);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, printer_combo);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, paper_size_combo);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, paper_size_label);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, paper_size_cell);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, portrait_radio);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, reverse_portrait_radio);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, landscape_radio);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialogPrivate, reverse_landscape_radio);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, printer_list);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, page_setup_list);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, custom_paper_list);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, printer_combo);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, paper_size_combo);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, paper_size_label);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, paper_size_cell);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, portrait_radio);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, reverse_portrait_radio);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, landscape_radio);
gtk_widget_class_bind_child (widget_class, GtkPageSetupUnixDialog, reverse_landscape_radio);
gtk_widget_class_bind_callback (widget_class, printer_changed_callback);
gtk_widget_class_bind_callback (widget_class, paper_size_changed);

View File

@ -259,8 +259,8 @@ gtk_path_bar_class_init (GtkPathBarClass *path_bar_class)
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkpathbar.ui");
gtk_widget_class_bind_child (widget_class, GtkPathBarPrivate, up_slider_button);
gtk_widget_class_bind_child (widget_class, GtkPathBarPrivate, down_slider_button);
gtk_widget_class_bind_child (widget_class, GtkPathBar, up_slider_button);
gtk_widget_class_bind_child (widget_class, GtkPathBar, down_slider_button);
gtk_widget_class_bind_callback (widget_class, gtk_path_bar_slider_button_press);
gtk_widget_class_bind_callback (widget_class, gtk_path_bar_slider_button_release);

View File

@ -480,69 +480,69 @@ gtk_print_unix_dialog_class_init (GtkPrintUnixDialogClass *class)
"/org/gtk/libgtk/gtkprintunixdialog.ui");
/* GtkTreeView / GtkTreeModel */
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_treeview);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_list);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_list_filter);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, page_setup_list);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, custom_paper_list);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_icon_column);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_name_column);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_location_column);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_status_column);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_icon_renderer);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_name_renderer);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_location_renderer);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, printer_status_renderer);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_treeview);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_list);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_list_filter);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, page_setup_list);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, custom_paper_list);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_icon_column);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_name_column);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_location_column);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_status_column);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_icon_renderer);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_name_renderer);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_location_renderer);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, printer_status_renderer);
/* General Widgetry */
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, notebook);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, all_pages_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, all_pages_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, current_page_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, selection_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, range_table);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, page_range_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, page_range_entry);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, copies_spin);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, collate_check);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, reverse_check);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, collate_image);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, page_layout_preview);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, scale_spin);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, page_set_combo);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, print_now_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, print_at_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, print_at_entry);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, print_hold_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, preview_button);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, paper_size_combo);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, paper_size_combo_label);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, paper_size_renderer);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, orientation_combo);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, orientation_combo_label);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, conflicts_widget);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, job_page);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, finishing_table);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, finishing_page);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, image_quality_table);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, image_quality_page);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, color_table);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, color_page);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, advanced_vbox);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, advanced_page);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, extension_point);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, notebook);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, all_pages_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, all_pages_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, current_page_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, selection_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, range_table);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, page_range_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, page_range_entry);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, copies_spin);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, collate_check);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, reverse_check);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, collate_image);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, page_layout_preview);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, scale_spin);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, page_set_combo);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, print_now_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, print_at_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, print_at_entry);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, print_hold_radio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, preview_button);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, paper_size_combo);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, paper_size_combo_label);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, paper_size_renderer);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, orientation_combo);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, orientation_combo_label);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, conflicts_widget);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, job_page);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, finishing_table);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, finishing_page);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, image_quality_table);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, image_quality_page);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, color_table);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, color_page);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, advanced_vbox);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, advanced_page);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, extension_point);
/* GtkPrinterOptionWidgets... */
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, pages_per_sheet);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, duplex);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, paper_type);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, paper_source);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, output_tray);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, job_prio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, billing_info);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, cover_before);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, cover_after);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialogPrivate, number_up_layout);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, pages_per_sheet);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, duplex);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, paper_type);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, paper_source);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, output_tray);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, job_prio);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, billing_info);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, cover_before);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, cover_after);
gtk_widget_class_bind_child (widget_class, GtkPrintUnixDialog, number_up_layout);
/* Callbacks handled in the UI */
gtk_widget_class_bind_callback (widget_class, gtk_print_unix_dialog_destroy);

View File

@ -348,15 +348,15 @@ _gtk_recent_chooser_default_class_init (GtkRecentChooserDefaultClass *klass)
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkrecentchooserdefault.ui");
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefaultPrivate, filter_combo_hbox);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefaultPrivate, filter_combo);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefaultPrivate, recent_view);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefaultPrivate, recent_store);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefaultPrivate, icon_column);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefaultPrivate, meta_column);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefaultPrivate, icon_renderer);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefaultPrivate, meta_renderer);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefaultPrivate, selection);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefault, filter_combo_hbox);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefault, filter_combo);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefault, recent_view);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefault, recent_store);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefault, icon_column);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefault, meta_column);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefault, icon_renderer);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefault, meta_renderer);
gtk_widget_class_bind_child (widget_class, GtkRecentChooserDefault, selection);
gtk_widget_class_bind_callback (widget_class, selection_changed_cb);
gtk_widget_class_bind_callback (widget_class, row_activated_cb);

View File

@ -360,13 +360,13 @@ gtk_scale_button_class_init (GtkScaleButtonClass *klass)
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gtk/libgtk/gtkscalebutton.ui");
gtk_widget_class_bind_child_internal (widget_class, GtkScaleButtonPrivate, plus_button);
gtk_widget_class_bind_child_internal (widget_class, GtkScaleButtonPrivate, minus_button);
gtk_widget_class_bind_child (widget_class, GtkScaleButtonPrivate, dock);
gtk_widget_class_bind_child (widget_class, GtkScaleButtonPrivate, box);
gtk_widget_class_bind_child (widget_class, GtkScaleButtonPrivate, scale);
gtk_widget_class_bind_child (widget_class, GtkScaleButtonPrivate, image);
gtk_widget_class_bind_child (widget_class, GtkScaleButtonPrivate, adjustment);
gtk_widget_class_bind_child_internal (widget_class, GtkScaleButton, plus_button);
gtk_widget_class_bind_child_internal (widget_class, GtkScaleButton, minus_button);
gtk_widget_class_bind_child (widget_class, GtkScaleButton, dock);
gtk_widget_class_bind_child (widget_class, GtkScaleButton, box);
gtk_widget_class_bind_child (widget_class, GtkScaleButton, scale);
gtk_widget_class_bind_child (widget_class, GtkScaleButton, image);
gtk_widget_class_bind_child (widget_class, GtkScaleButton, adjustment);
gtk_widget_class_bind_callback (widget_class, cb_dock_button_press);
gtk_widget_class_bind_callback (widget_class, cb_dock_key_release);

View File

@ -413,10 +413,10 @@ gtk_search_bar_class_init (GtkSearchBarClass *klass)
g_object_class_install_properties (object_class, LAST_PROPERTY, widget_props);
gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/gtksearchbar.ui");
gtk_widget_class_bind_child_internal (widget_class, GtkSearchBarPrivate, toolbar);
gtk_widget_class_bind_child_internal (widget_class, GtkSearchBarPrivate, revealer);
gtk_widget_class_bind_child_internal (widget_class, GtkSearchBarPrivate, box_center);
gtk_widget_class_bind_child_internal (widget_class, GtkSearchBarPrivate, close_button);
gtk_widget_class_bind_child_internal (widget_class, GtkSearchBar, toolbar);
gtk_widget_class_bind_child_internal (widget_class, GtkSearchBar, revealer);
gtk_widget_class_bind_child_internal (widget_class, GtkSearchBar, box_center);
gtk_widget_class_bind_child_internal (widget_class, GtkSearchBar, close_button);
}
static void

View File

@ -180,9 +180,9 @@ gtk_statusbar_class_init (GtkStatusbarClass *class)
/* Bind class to template
*/
gtk_widget_class_set_template_from_resource (widget_class, "/org/gtk/libgtk/gtkstatusbar.ui");
gtk_widget_class_bind_child_internal (widget_class, GtkStatusbarPrivate, message_area);
gtk_widget_class_bind_child (widget_class, GtkStatusbarPrivate, frame);
gtk_widget_class_bind_child (widget_class, GtkStatusbarPrivate, label);
gtk_widget_class_bind_child_internal (widget_class, GtkStatusbar, message_area);
gtk_widget_class_bind_child (widget_class, GtkStatusbar, frame);
gtk_widget_class_bind_child (widget_class, GtkStatusbar, label);
gtk_widget_class_set_accessible_type (widget_class, GTK_TYPE_STATUSBAR_ACCESSIBLE);
}

View File

@ -11348,7 +11348,6 @@ gtk_widget_real_destroy (GtkWidget *object)
if (priv->auto_children)
{
GType class_type;
GtkWidgetClass *class;
GSList *l;
@ -11397,21 +11396,17 @@ gtk_widget_real_destroy (GtkWidget *object)
if (!class->priv->template)
continue;
class_type = G_OBJECT_CLASS_TYPE (class);
for (l = class->priv->template->children; l; l = l->next)
{
AutomaticChildClass *child_class = l->data;
if (child_class->offset >= 0)
if (child_class->offset != 0)
{
gpointer class_private;
GObject **destination;
gpointer field_p;
/* Nullify instance private data for internal children */
class_private = G_TYPE_INSTANCE_GET_PRIVATE (widget, class_type, gpointer);
destination = G_STRUCT_MEMBER_P (class_private, child_class->offset);
*destination = NULL;
field_p = G_STRUCT_MEMBER_P (widget, child_class->offset);
(* (gpointer *) field_p) = NULL;
}
}
}
@ -15658,15 +15653,13 @@ setup_automatic_child (GtkWidgetTemplate *template_data,
auto_child_hash = get_auto_child_hash (widget, class_type, TRUE);
g_hash_table_insert (auto_child_hash, child_class->name, g_object_ref (object));
if (child_class->offset >= 0)
if (child_class->offset != 0)
{
gpointer class_private;
GObject **destination;
gpointer field_p;
/* Assign 'object' to the specified offset in the instance private data */
class_private = G_TYPE_INSTANCE_GET_PRIVATE (widget, class_type, gpointer);
destination = G_STRUCT_MEMBER_P (class_private, child_class->offset);
*destination = object;
/* Assign 'object' to the specified offset in the instance (or private) data */
field_p = G_STRUCT_MEMBER_P (widget, child_class->offset);
(* (gpointer *) field_p) = object;
}
return TRUE;
@ -15919,12 +15912,15 @@ gtk_widget_class_set_connect_func (GtkWidgetClass *widget_class,
* @name: The "id" of the child defined in the template XML
* @internal_child: Whether the child should be accessible as an "internal-child"
* when this class is used in GtkBuilder XML
* @struct_offset: The structure offset into the composite widget's instance private structure
* @struct_offset: The structure offset into the composite widget's instance public or private structure
* where the automated child pointer should be set, or -1 to not assign the pointer.
*
* Automatically assign an object declared in the class template XML to be set to a location
* on a freshly built instance's private data, or alternatively accessible via gtk_widget_get_automated_child().
*
* The struct can point either into the public instance, then you should use G_STRUCT_OFFSET(WidgetType, member)
* for @struct_offset, or in the private struct, then you should use G_PRIVATE_OFFSET(WidgetType, member).
*
* An explicit strong reference will be held automatically for the duration of your
* instance's life cycle, it will be released automatically when #GObjectClass.dispose() runs
* on your instance and if a @struct_offset that is >= 0 is specified, then the automatic location

View File

@ -1176,7 +1176,7 @@ void gtk_widget_remove_tick_callback (GtkWidget *widget,
/**
* gtk_widget_class_bind_child:
* @widget_class: a #GtkWidgetClass
* @private_data_type: the type of this widget class's instance private data
* @data_type: the type name of this widget
* @member_name: name of the instance private member on @private_data_type
*
* Shorthand for gtk_widget_class_automate_child(). This macro assumes that
@ -1185,14 +1185,14 @@ void gtk_widget_remove_tick_callback (GtkWidget *widget,
*
* Since: 3.10
*/
#define gtk_widget_class_bind_child(widget_class, private_data_type, member_name) \
#define gtk_widget_class_bind_child(widget_class, data_type, member_name) \
gtk_widget_class_automate_child (widget_class, #member_name, FALSE, \
G_STRUCT_OFFSET (private_data_type, member_name))
G_PRIVATE_OFFSET (data_type, member_name))
/**
* gtk_widget_class_bind_child_internal:
* @widget_class: a #GtkWidgetClass
* @private_data_type: the type name of this widget class's instance private data
* @data_type: the type name of this widget
* @member_name: name of the instance private member on @private_data_type
*
* Shorthand for gtk_widget_class_automate_child(). Essentially the same as
@ -1201,9 +1201,9 @@ void gtk_widget_remove_tick_callback (GtkWidget *widget,
*
* Since: 3.10
*/
#define gtk_widget_class_bind_child_internal(widget_class, private_data_type, member_name) \
#define gtk_widget_class_bind_child_internal(widget_class, data_type, member_name) \
gtk_widget_class_automate_child (widget_class, #member_name, TRUE, \
G_STRUCT_OFFSET (private_data_type, member_name))
G_PRIVATE_OFFSET (data_type, member_name))
GDK_AVAILABLE_IN_3_10
void gtk_widget_init_template (GtkWidget *widget);