r16790 - gnucash/branches/2.2/src/gnome-utils - [r16727] Wait for pending events before displaying the tree view (#463678)

Andreas Köhler andi5 at cvs.gnucash.org
Fri Jan 4 19:51:42 EST 2008


Author: andi5
Date: 2008-01-04 19:51:42 -0500 (Fri, 04 Jan 2008)
New Revision: 16790
Trac: http://svn.gnucash.org/trac/changeset/16790

Modified:
   gnucash/branches/2.2/src/gnome-utils/gnc-tree-view-account.c
Log:
[r16727] Wait for pending events before displaying the tree view (#463678)


Modified: gnucash/branches/2.2/src/gnome-utils/gnc-tree-view-account.c
===================================================================
--- gnucash/branches/2.2/src/gnome-utils/gnc-tree-view-account.c	2008-01-05 00:51:33 UTC (rev 16789)
+++ gnucash/branches/2.2/src/gnome-utils/gnc-tree-view-account.c	2008-01-05 00:51:42 UTC (rev 16790)
@@ -1119,6 +1119,11 @@
   gtk_tree_path_free(parent_path);
 
   gtk_tree_selection_select_path (selection, s_path);
+
+  /* give gtk+ a chance to resize the tree view first by handling pending
+   * configure events */
+  while (gtk_events_pending ())
+    gtk_main_iteration ();
   gtk_tree_view_scroll_to_cell (GTK_TREE_VIEW(view), s_path, NULL, FALSE, 0.0, 0.0);
   debug_path(LEAVE, s_path);
   gtk_tree_path_free(s_path);



More information about the gnucash-changes mailing list