r15791 - gnucash/trunk/src - Implement idea from Mike Alexander (in #346063) to key lot scrubbing
David Hampton
hampton at cvs.gnucash.org
Wed Apr 4 00:58:08 EDT 2007
Author: hampton
Date: 2007-04-04 00:58:07 -0400 (Wed, 04 Apr 2007)
New Revision: 15791
Trac: http://svn.gnucash.org/trac/changeset/15791
Modified:
gnucash/trunk/src/engine/Transaction.c
gnucash/trunk/src/gnome/gnc-plugin-page-account-tree.c
gnucash/trunk/src/gnome/window-reconcile.c
Log:
Implement idea from Mike Alexander (in #346063) to key lot scrubbing
off the environment variable GNC_AUTO_SCRUB_LOTS instead of commenting
it out of the code. This make it easier for developers to test/users
to try lot scrubbing.
Modified: gnucash/trunk/src/engine/Transaction.c
===================================================================
--- gnucash/trunk/src/engine/Transaction.c 2007-04-04 04:36:16 UTC (rev 15790)
+++ gnucash/trunk/src/engine/Transaction.c 2007-04-04 04:58:07 UTC (rev 15791)
@@ -1021,7 +1021,8 @@
/* Get the cap gains into a consistent state as well. */
/* Lot Scrubbing is temporarily disabled. */
- //xaccTransScrubGains (trans, NULL);
+ if (g_getenv("GNC_AUTO_SCRUB_LOTS") != NULL)
+ xaccTransScrubGains (trans, NULL);
/* Allow scrubbing in transaction commit again */
scrub_data = 1;
Modified: gnucash/trunk/src/gnome/gnc-plugin-page-account-tree.c
===================================================================
--- gnucash/trunk/src/gnome/gnc-plugin-page-account-tree.c 2007-04-04 04:36:16 UTC (rev 15790)
+++ gnucash/trunk/src/gnome/gnc-plugin-page-account-tree.c 2007-04-04 04:58:07 UTC (rev 15791)
@@ -1165,7 +1165,8 @@
xaccAccountScrubImbalance (account);
// XXX: Lots are disabled
- //xaccAccountScrubLots (account);
+ if (g_getenv("GNC_AUTO_SCRUB_LOTS") != NULL)
+ xaccAccountScrubLots(account);
gnc_resume_gui_refresh ();
}
@@ -1183,7 +1184,8 @@
xaccAccountTreeScrubImbalance (account);
// XXX: Lots are disabled
- //xaccAccountTreeScrubLots (account);
+ if (g_getenv("GNC_AUTO_SCRUB_LOTS") != NULL)
+ xaccAccountTreeScrubLots(account);
gnc_resume_gui_refresh ();
}
@@ -1198,7 +1200,8 @@
xaccAccountTreeScrubOrphans (root);
xaccAccountTreeScrubImbalance (root);
// XXX: Lots are disabled
- // xaccAccountTreeScrubLots (root);
+ if (g_getenv("GNC_AUTO_SCRUB_LOTS") != NULL)
+ xaccAccountTreeScrubLots(root);
gnc_resume_gui_refresh ();
}
Modified: gnucash/trunk/src/gnome/window-reconcile.c
===================================================================
--- gnucash/trunk/src/gnome/window-reconcile.c 2007-04-04 04:36:16 UTC (rev 15790)
+++ gnucash/trunk/src/gnome/window-reconcile.c 2007-04-04 04:58:07 UTC (rev 15791)
@@ -1229,7 +1229,8 @@
xaccAccountTreeScrubImbalance (account);
// XXX: Lots are disabled.
- //xaccAccountTreeScrubLots (account);
+ if (g_getenv("GNC_AUTO_SCRUB_LOTS") != NULL)
+ xaccAccountTreeScrubLots(account);
gnc_resume_gui_refresh ();
}
More information about the gnucash-changes
mailing list