[Gnucash-changes] Properly set the window field in the
gnc_split_register data structure
David Hampton
hampton at cvs.gnucash.org
Tue Aug 2 22:58:27 EDT 2005
Log Message:
-----------
Properly set the window field in the gnc_split_register data structure
when installing the page into a GncEmbeddedWindow.
Tags:
----
gnucash-gnome2-dev
Modified Files:
--------------
gnucash/src/gnome:
gnc-plugin-page-register.c
Revision Data
-------------
Index: gnc-plugin-page-register.c
===================================================================
RCS file: /home/cvs/cvsroot/gnucash/src/gnome/Attic/gnc-plugin-page-register.c,v
retrieving revision 1.1.2.34
retrieving revision 1.1.2.35
diff -Lsrc/gnome/gnc-plugin-page-register.c -Lsrc/gnome/gnc-plugin-page-register.c -u -r1.1.2.34 -r1.1.2.35
--- src/gnome/gnc-plugin-page-register.c
+++ src/gnome/gnc-plugin-page-register.c
@@ -575,6 +575,7 @@
{
GncPluginPageRegister *page;
GncPluginPageRegisterPrivate *priv;
+ GncWindow *gnc_window;
guint numRows;
GtkWidget *gsr;
SplitRegister *sr;
@@ -597,8 +598,10 @@
numRows = priv->lines_default;
}
+ numRows = max(numRows, 50);
+ gnc_window = GNC_WINDOW(GNC_PLUGIN_PAGE(page)->window);
gsr = gnc_split_reg_new(priv->ledger,
- GTK_WINDOW(GNC_PLUGIN_PAGE(page)->window),
+ gnc_window_get_gtk_window(gnc_window),
numRows, 0, priv->disallowCaps);
priv->gsr = (GNCSplitReg *)gsr;
gtk_widget_show (gsr);
@@ -673,7 +676,8 @@
g_return_if_fail (GNC_IS_PLUGIN_PAGE_REGISTER (plugin_page));
page = GNC_PLUGIN_PAGE_REGISTER(plugin_page);
- page->priv->gsr->window = window;
+ page->priv->gsr->window =
+ GTK_WIDGET(gnc_window_get_gtk_window(GNC_WINDOW(window)));
}
static void
More information about the gnucash-changes
mailing list