[Gnucash-changes] r12224 - gnucash/trunk/src/gnome - Turn on gconf for the budget plugin page's tree view account.

Chris Shoemaker chris at cvs.gnucash.org
Sat Dec 31 01:20:35 EST 2005


Author: chris
Date: 2005-12-31 01:20:35 -0500 (Sat, 31 Dec 2005)
New Revision: 12224
Trac: http://svn.gnucash.org/trac/changeset/12224

Modified:
   gnucash/trunk/src/gnome/gnc-plugin-page-budget.c
Log:
Turn on gconf for the budget plugin page's tree view account.

Doesn't seem to work quite yet.  It does save the settings in the user's 
gconf directory, but the tree view doesn't remember things like sort order,
which the account-tree page's account treeview does remember.  There must be 
something else needed...



Modified: gnucash/trunk/src/gnome/gnc-plugin-page-budget.c
===================================================================
--- gnucash/trunk/src/gnome/gnc-plugin-page-budget.c	2005-12-31 06:06:51 UTC (rev 12223)
+++ gnucash/trunk/src/gnome/gnc-plugin-page-budget.c	2005-12-31 06:20:35 UTC (rev 12224)
@@ -30,10 +30,6 @@
  * basis, instead of a whole row (account) at one time.  But, that
  * would require some major coding.
  *
- * *) Right now, the account-type filter is not saved anywhere.  Where
- * should it be saved?  Per budget?  Gconf?
- *
- *
  */
 
 #include "config.h"
@@ -68,14 +64,13 @@
 #include "gnc-recurrence.h"
 #include "Recurrence.h"
 #include "gnc-tree-model-account-types.h"
-#include "gnc-plugin-page-account-tree.h" // just until filter funcs find a home
 
 
 /* This static indicates the debugging module that this .o belongs to.  */
 static QofLogModule log_module = GNC_MOD_BUDGET;
 
 #define PLUGIN_PAGE_BUDGET_CM_CLASS "plugin-page-budget"
-//#define GCONF_SECTION "window/pages/budget"
+#define GCONF_SECTION "window/pages/budget"
 
 /************************************************************
  *                        Prototypes                        *
@@ -263,11 +258,6 @@
     GtkActionGroup *action_group;
     GncPluginPageBudgetPrivate *priv;
     GncPluginPage *parent;
-    const gchar *url = NULL;
-    //int options_id;
-    //SCM find_options;
-    //SCM temp;
-    URLType type;
 
     ENTER("page %p", plugin_page);
     priv = GNC_PLUGIN_PAGE_BUDGET_GET_PRIVATE(plugin_page);
@@ -293,20 +283,6 @@
                                   plugin_page);
     gnc_plugin_init_short_names (action_group, toolbar_labels);
 
-    // FIXME: need to test this url case
-    if(!url) {
-    } else {
-        char * location = NULL;
-        char * label = NULL;
-
-        /* if an URL is specified, it should look like
-         * gnc-budget:id=17 .  We want to get the number out,
-         * then look up the options in the global DB. */
-        type = gnc_html_parse_url(NULL, url, &location, &label);
-        g_free (location);
-        g_free (label);
-    }
-
     /* Visisble types */
     priv->fd.visible_types = -1; /* Start with all types */
     priv->fd.hide_zero_total = FALSE;
@@ -398,8 +374,9 @@
                         TRUE, TRUE, 0);
 
     tree_view = gnc_tree_view_account_new(FALSE);
-    gnc_tree_view_configure_columns(
-        GNC_TREE_VIEW(tree_view), "Name", NULL);
+    g_object_set(G_OBJECT(tree_view), "gconf-section", GCONF_SECTION, NULL);
+
+    gnc_tree_view_configure_columns(GNC_TREE_VIEW(tree_view), "Name", NULL);
     priv->tree_view = tree_view;
     selection = gtk_tree_view_get_selection(tree_view);
     gtk_tree_selection_set_mode(selection, GTK_SELECTION_MULTIPLE);



More information about the gnucash-changes mailing list