diff options
author | Carlos Garnacho <carlos@imendio.com> | 2008-06-24 10:22:40 +0000 |
---|---|---|
committer | Carlos Garnacho <carlosg@src.gnome.org> | 2008-06-24 10:22:40 +0000 |
commit | 60e1b3ea89c6103cd5b000758721cda1a6a3db76 (patch) | |
tree | 5e55be69b74da413703d9b7e3c53f57c196f44bd /docs | |
parent | a13f698b3a1d5d3376cc60c3ea99b1857f1f8a19 (diff) | |
download | gdk-pixbuf-60e1b3ea89c6103cd5b000758721cda1a6a3db76.tar.gz |
Remove container implementation, which isn't thought for handling
2008-06-24 Carlos Garnacho <carlos@imendio.com>
* gtk/gtkdialog.[ch]: Remove container implementation, which isn't
thought for handling non-direct children. Fixes #539732.
(gtk_dialog_pack_start) (gtk_dialog_pack_end): Removed as well, it
doesn't provide enough control to API users (removing, reordering...),
this is better handled through:
(gtk_dialog_get_content_area): New function which just returns
dialog->vbox.
* gtk/gtk.symbols: Modify accordingly.
* docs/reference/gtk/tmpl/gtkdialog.sgml: Update docs to recommend
using gtk_dialog_get_[action|content]_area() instead of accessing
dialog struct members directly.
svn path=/trunk/; revision=20680
Diffstat (limited to 'docs')
-rw-r--r-- | docs/reference/gtk/tmpl/gtkdialog.sgml | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/docs/reference/gtk/tmpl/gtkdialog.sgml b/docs/reference/gtk/tmpl/gtkdialog.sgml index b6efb0c79..1cbb83672 100644 --- a/docs/reference/gtk/tmpl/gtkdialog.sgml +++ b/docs/reference/gtk/tmpl/gtkdialog.sgml @@ -30,9 +30,8 @@ buttons. <para> If 'dialog' is a newly created dialog, the two primary areas of the window -can be accessed as <literal>GTK_DIALOG(dialog)->vbox</literal> and -<literal>GTK_DIALOG(dialog)->action_area</literal>, -as can be seen from the example, below. +can be accessed through gtk_dialog_get_content_area() and +gtk_dialog_get_action_area(), as can be seen from the example, below. </para> <para> @@ -74,7 +73,7 @@ dialog contents manually if you had more than a simple message in the dialog. void quick_message (gchar *message) { - GtkWidget *dialog, *label; + GtkWidget *dialog, *label, *content_area; /* Create the widgets */ @@ -84,6 +83,7 @@ void quick_message (gchar *message) { GTK_STOCK_OK, GTK_RESPONSE_NONE, NULL); + content_area = gtk_dialog_get_content_area (GTK_DIALOG (dialog)); label = gtk_label_new (message); /* Ensure that the dialog box is destroyed when the user responds. */ @@ -95,8 +95,7 @@ void quick_message (gchar *message) { /* Add the label, and show everything we've added to the dialog. */ - gtk_container_add (GTK_CONTAINER (GTK_DIALOG(dialog)->vbox), - label); + gtk_container_add (GTK_CONTAINER (content_area), label); gtk_widget_show_all (dialog); } |