[gtk+] Add a more complex widget in the flipping assistant
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] Add a more complex widget in the flipping assistant
- Date: Thu, 29 Oct 2015 23:30:09 +0000 (UTC)
commit ffaaa1e66eef00d1dbaf28ae4ab9e4cdd74f1bae
Author: Sébastien Granjoux <seb sfo free fr>
Date: Mon Oct 26 21:52:34 2015 +0100
Add a more complex widget in the flipping assistant
This reproduces the problem from bug
https://bugzilla.gnome.org/show_bug.cgi?id=756385
gtk/gtkassistant.c | 1 -
tests/testassistant.c | 11 ++++++++---
2 files changed, 8 insertions(+), 4 deletions(-)
---
diff --git a/gtk/gtkassistant.c b/gtk/gtkassistant.c
index 91270b9..b1d400d 100644
--- a/gtk/gtkassistant.c
+++ b/gtk/gtkassistant.c
@@ -1134,7 +1134,6 @@ assistant_remove_page_cb (GtkContainer *container,
return;
page_info = element->data;
-g_print ("remove page cb: %s\n", page_info->title);
/* If this is the current page, we need to switch away. */
if (page_info == priv->current_page)
diff --git a/tests/testassistant.c b/tests/testassistant.c
index bfce399..fec7f69 100644
--- a/tests/testassistant.c
+++ b/tests/testassistant.c
@@ -607,7 +607,7 @@ flip_pages (GtkButton *button, GtkAssistant *assistant)
gtk_assistant_remove_page (assistant, 1);
gtk_assistant_insert_page (assistant, page, 2);
- gtk_widget_show (page);
+ gtk_widget_show_all (page);
gtk_assistant_set_page_title (GTK_ASSISTANT (assistant), page, title);
gtk_assistant_set_page_complete (GTK_ASSISTANT (assistant), page, TRUE);
@@ -650,8 +650,13 @@ create_page_flipping_assistant (GtkWidget *widget)
gtk_assistant_set_page_title (GTK_ASSISTANT (assistant), page, "Page 1");
gtk_assistant_set_page_complete (GTK_ASSISTANT (assistant), page, TRUE);
- page = get_test_page ("Page 2");
- gtk_widget_show (page);
+ page = gtk_box_new (GTK_ORIENTATION_VERTICAL, 0);
+ gtk_box_pack_start (GTK_BOX (page),
+ get_test_page ("Page 2"),
+ TRUE,
+ TRUE,
+ 0);
+ gtk_widget_show_all (page);
gtk_assistant_append_page (GTK_ASSISTANT (assistant), page);
gtk_assistant_set_page_title (GTK_ASSISTANT (assistant), page, "Page 2");
gtk_assistant_set_page_complete (GTK_ASSISTANT (assistant), page, TRUE);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]