r21984 - gnucash/trunk/src/engine - Use better variable name to avoid confusion with is_cn
Geert Janssens
gjanssens at code.gnucash.org
Fri Feb 10 10:32:16 EST 2012
Author: gjanssens
Date: 2012-02-10 10:32:16 -0500 (Fri, 10 Feb 2012)
New Revision: 21984
Trac: http://svn.gnucash.org/trac/changeset/21984
Modified:
gnucash/trunk/src/engine/gncEntry.c
Log:
Use better variable name to avoid confusion with is_cn
Modified: gnucash/trunk/src/engine/gncEntry.c
===================================================================
--- gnucash/trunk/src/engine/gncEntry.c 2012-02-10 15:32:07 UTC (rev 21983)
+++ gnucash/trunk/src/engine/gncEntry.c 2012-02-10 15:32:16 UTC (rev 21984)
@@ -1344,48 +1344,48 @@
entry->values_dirty = FALSE;
}
-void gncEntryGetValue (GncEntry *entry, gboolean is_inv, gnc_numeric *value,
+void gncEntryGetValue (GncEntry *entry, gboolean is_cust_doc, gnc_numeric *value,
gnc_numeric *discount_value, gnc_numeric *tax_value,
GList **tax_values)
{
if (!entry) return;
gncEntryRecomputeValues (entry);
if (value)
- *value = (is_inv ? entry->i_value : entry->b_value);
+ *value = (is_cust_doc ? entry->i_value : entry->b_value);
if (discount_value)
- *discount_value = (is_inv ? entry->i_disc_value : gnc_numeric_zero());
+ *discount_value = (is_cust_doc ? entry->i_disc_value : gnc_numeric_zero());
if (tax_value)
- *tax_value = (is_inv ? entry->i_tax_value : entry->b_tax_value);
+ *tax_value = (is_cust_doc ? entry->i_tax_value : entry->b_tax_value);
if (tax_values)
- *tax_values = (is_inv ? entry->i_tax_values : entry->b_tax_values);
+ *tax_values = (is_cust_doc ? entry->i_tax_values : entry->b_tax_values);
}
-gnc_numeric gncEntryReturnValue (GncEntry *entry, gboolean is_inv)
+gnc_numeric gncEntryReturnValue (GncEntry *entry, gboolean is_cust_doc)
{
if (!entry) return gnc_numeric_zero();
gncEntryRecomputeValues (entry);
- return (is_inv ? entry->i_value_rounded : entry->b_value_rounded);
+ return (is_cust_doc ? entry->i_value_rounded : entry->b_value_rounded);
}
-gnc_numeric gncEntryReturnTaxValue (GncEntry *entry, gboolean is_inv)
+gnc_numeric gncEntryReturnTaxValue (GncEntry *entry, gboolean is_cust_doc)
{
if (!entry) return gnc_numeric_zero();
gncEntryRecomputeValues (entry);
- return (is_inv ? entry->i_tax_value_rounded : entry->b_tax_value_rounded);
+ return (is_cust_doc ? entry->i_tax_value_rounded : entry->b_tax_value_rounded);
}
-AccountValueList * gncEntryReturnTaxValues (GncEntry *entry, gboolean is_inv)
+AccountValueList * gncEntryReturnTaxValues (GncEntry *entry, gboolean is_cust_doc)
{
if (!entry) return NULL;
gncEntryRecomputeValues (entry);
- return (is_inv ? entry->i_tax_values : entry->b_tax_values);
+ return (is_cust_doc ? entry->i_tax_values : entry->b_tax_values);
}
-gnc_numeric gncEntryReturnDiscountValue (GncEntry *entry, gboolean is_inv)
+gnc_numeric gncEntryReturnDiscountValue (GncEntry *entry, gboolean is_cust_doc)
{
if (!entry) return gnc_numeric_zero();
gncEntryRecomputeValues (entry);
- return (is_inv ? entry->i_disc_value_rounded : gnc_numeric_zero());
+ return (is_cust_doc ? entry->i_disc_value_rounded : gnc_numeric_zero());
}
/* XXX this existence of this routine is just wrong */
More information about the gnucash-changes
mailing list