diff options
author | Alberto Garcia <agarcia@igalia.com> | 2009-02-04 19:39:39 +0000 |
---|---|---|
committer | Alberto Garcia <agarcia@igalia.com> | 2009-02-04 19:39:39 +0000 |
commit | a65c18afe2970de158fc7e1d18c1445b15f1ec3d (patch) | |
tree | de0a1f071cd2557351c9435c9bb361a7a508d7a7 /examples/hildon-edit-toolbar-example.c | |
parent | 095e1a32375b31969818f5106290ff6579806d01 (diff) |
2009-02-04 Alberto Garcia <agarcia@igalia.com>
* doc/hildon-sections.txt
* src/hildon-window-private.h
* src/hildon-window.h
* src/hildon-window.c (hildon_window_init)
(hildon_window_realize, hildon_window_unrealize)
(hildon_window_map, hildon_window_unmap, hildon_window_expose)
(hildon_window_size_request, hildon_window_size_allocate)
(hildon_window_forall, hildon_window_show_all)
(hildon_window_destroy, +paint_edit_toolbar)
(+hildon_window_set_edit_toolbar):
New hildon_window_set_edit_toolbar() method, to add a
HildonEditToolbar to a window without having to pack it manually.
Reorganize hildon_window_size_allocate()
* src/hildon-edit-toolbar.c: Update documentation.
* examples/hildon-edit-toolbar-example.c (edit_window): Update
example to use the new API.
Fixes: NB#98039 (Wishlist: hildon_window_add_edit_toolbar())
Diffstat (limited to 'examples/hildon-edit-toolbar-example.c')
-rw-r--r-- | examples/hildon-edit-toolbar-example.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/examples/hildon-edit-toolbar-example.c b/examples/hildon-edit-toolbar-example.c index d87f09b..15a88b2 100644 --- a/examples/hildon-edit-toolbar-example.c +++ b/examples/hildon-edit-toolbar-example.c @@ -141,23 +141,20 @@ edit_window (void) { GtkWidget *window; GtkWidget *iconview; - GtkWidget *vbox; GtkWidget *toolbar; GtkWidget *area; window = hildon_stackable_window_new (); gtk_container_set_border_width (GTK_CONTAINER (window), 6); - vbox = gtk_vbox_new (FALSE, 10); toolbar = hildon_edit_toolbar_new_with_text ("Choose items to delete", "Delete"); area = hildon_pannable_area_new (); iconview = create_icon_view (EDIT_MODE); - gtk_container_add (GTK_CONTAINER (area), iconview); - gtk_box_pack_start (GTK_BOX (vbox), toolbar, FALSE, FALSE, 0); - gtk_box_pack_start (GTK_BOX (vbox), area, TRUE, TRUE, 0); + hildon_window_set_edit_toolbar (HILDON_WINDOW (window), HILDON_EDIT_TOOLBAR (toolbar)); - gtk_container_add (GTK_CONTAINER (window), vbox); + gtk_container_add (GTK_CONTAINER (area), iconview); + gtk_container_add (GTK_CONTAINER (window), area); g_signal_connect (toolbar, "button-clicked", G_CALLBACK (delete_button_clicked), iconview); g_signal_connect_swapped (toolbar, "arrow-clicked", G_CALLBACK (gtk_widget_destroy), window); |