Replace NS_ISO with NS_CURRENCY. This substitution was already

performed by the called functions, so there this change is purely
cosmetic.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@13776 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
David Hampton 2006-04-14 02:36:00 +00:00
parent df6d6c6835
commit 9c24273f83
11 changed files with 36 additions and 18 deletions

View File

@ -1,3 +1,21 @@
2006-04-13 David Hampton <hampton@employees.org>
* src/import-export/qif-import/druid-qif-import.c:
* src/import-export/binary-import/druid-commodity.c:
* src/import-export/ofx/gnc-ofx-import.c:
* src/import-export/hbci/druid-hbci-initial.c:
* src/gnome-utils/dialog-preferences.c:
* src/gnome-utils/gnc-currency-edit.c:
* src/app-utils/gnc-euro.c:
* src/app-utils/options.scm:
* src/app-utils/gnc-ui-util.c: Replace NS_ISO with NS_CURRENCY.
This substitution was already performed by the called functions,
so there this change is purely cosmetic.
* src/gnome-utils/dialog-commodity.c:
* src/engine/gnc-commodity.[ch]: Added a couple of comments
related to the change from NS_ISO to NS_CURRENCY.
2006-04-13 Andreas Köhler <andi5.py@gmx.net>
* src/engine/Group.c: Fix loop of split account reassignments in

View File

@ -236,5 +236,5 @@ gnc_get_euro (void)
table = gnc_book_get_commodity_table (gnc_get_current_book ());
return gnc_commodity_table_lookup (table, GNC_COMMODITY_NS_ISO, "EUR");
return gnc_commodity_table_lookup (table, GNC_COMMODITY_NS_CURRENCY, "EUR");
}

View File

@ -814,7 +814,7 @@ gnc_locale_default_currency_nodefault (void)
table = gnc_get_current_commodities ();
code = gnc_locale_default_iso_currency_code ();
currency = gnc_commodity_table_lookup (table, GNC_COMMODITY_NS_ISO, code);
currency = gnc_commodity_table_lookup (table, GNC_COMMODITY_NS_CURRENCY, code);
return (currency ? currency : NULL);
}
@ -826,7 +826,7 @@ gnc_locale_default_currency (void)
return (currency ? currency :
gnc_commodity_table_lookup (gnc_get_current_commodities (),
GNC_COMMODITY_NS_ISO, "USD"));
GNC_COMMODITY_NS_CURRENCY, "USD"));
}
@ -838,14 +838,14 @@ gnc_default_currency (void)
if (user_default_currency)
return gnc_commodity_table_lookup(gnc_get_current_commodities(),
GNC_COMMODITY_NS_ISO,
GNC_COMMODITY_NS_CURRENCY,
user_default_currency);
choice = gnc_gconf_get_string(GCONF_GENERAL, KEY_CURRENCY_CHOICE, NULL);
if (choice && strcmp(choice, "other") == 0) {
mnemonic = gnc_gconf_get_string(GCONF_GENERAL, KEY_CURRENCY_OTHER, NULL);
currency = gnc_commodity_table_lookup(gnc_get_current_commodities(),
GNC_COMMODITY_NS_ISO, mnemonic);
GNC_COMMODITY_NS_CURRENCY, mnemonic);
DEBUG("mnemonic %s, result %p", mnemonic, currency);
g_free(mnemonic);
g_free(choice);
@ -869,7 +869,7 @@ gnc_default_report_currency (void)
if (user_report_currency)
return gnc_commodity_table_lookup(gnc_get_current_commodities(),
GNC_COMMODITY_NS_ISO,
GNC_COMMODITY_NS_CURRENCY,
user_report_currency);
choice = gnc_gconf_get_string(GCONF_GENERAL_REPORT,
KEY_CURRENCY_CHOICE, NULL);
@ -877,7 +877,7 @@ gnc_default_report_currency (void)
mnemonic = gnc_gconf_get_string(GCONF_GENERAL_REPORT,
KEY_CURRENCY_OTHER, NULL);
currency = gnc_commodity_table_lookup(gnc_get_current_commodities(),
GNC_COMMODITY_NS_ISO, mnemonic);
GNC_COMMODITY_NS_CURRENCY, mnemonic);
DEBUG("mnemonic %s, result %p", mnemonic, currency);
g_free(choice);
g_free(mnemonic);

View File

@ -282,7 +282,7 @@
(if (string? currency)
(gnc:commodity-table-lookup
(gnc:book-get-commodity-table (gnc:get-current-book))
GNC_COMMODITY_NS_ISO currency)
GNC_COMMODITY_NS_CURRENCY currency)
currency))
(let* ((value (currency->scm default-value))

View File

@ -955,7 +955,7 @@ gnc_prefs_currency_edit_gconf_cb (GNCCurrencyEdit *gce,
mnemonic = gconf_value_get_string(entry->value);
DEBUG("gce %p, mnemonic %s", gce, mnemonic);
currency = gnc_commodity_table_lookup(gnc_get_current_commodities(),
GNC_COMMODITY_NS_ISO, mnemonic);
GNC_COMMODITY_NS_CURRENCY, mnemonic);
/* If there isn't any such commodity, get the default */
if (!currency) {
@ -994,7 +994,7 @@ gnc_prefs_connect_currency_edit (GNCCurrencyEdit *gce)
name = gtk_widget_get_name(GTK_WIDGET(gce)) + PREFIX_LEN;
mnemonic = gnc_gconf_get_string(name, NULL, NULL);
currency = gnc_commodity_table_lookup(gnc_get_current_commodities(),
GNC_COMMODITY_NS_ISO, mnemonic);
GNC_COMMODITY_NS_CURRENCY, mnemonic);
if (mnemonic)
g_free(mnemonic);

View File

@ -186,7 +186,7 @@ fill_currencies(GNCCurrencyEdit *gce)
GList *currencies;
currencies = gnc_commodity_table_get_commodities
(gnc_get_current_commodities (), GNC_COMMODITY_NS_ISO);
(gnc_get_current_commodities (), GNC_COMMODITY_NS_CURRENCY);
currencies = g_list_sort(currencies, currency_compare);
g_list_foreach(currencies, (GFunc)add_item, gce);
g_list_free(currencies);
@ -297,7 +297,7 @@ gnc_currency_edit_get_currency (GNCCurrencyEdit *gce)
if (name != NULL)
*name = '\0';
commodity = gnc_commodity_table_lookup (gnc_get_current_commodities (),
GNC_COMMODITY_NS_ISO,
GNC_COMMODITY_NS_CURRENCY,
mnemonic);
g_free(mnemonic);
} else {

View File

@ -176,7 +176,7 @@ gnc_ui_commodity_druid_create(const char * filename)
/* if the mnemonic is an ISO-4217 currency, use that as
* the default */
found = gnc_commodity_table_lookup(gnc_get_current_commodities(),
GNC_COMMODITY_NS_ISO,
GNC_COMMODITY_NS_CURRENCY,
gnc_commodity_get_mnemonic(lost));
/* otherwise, guess that it's a NASDAQ security. */

View File

@ -395,7 +395,7 @@ on_accountlist_select_row (GtkCList *clist, gint row,
(strlen(AB_Account_GetCurrency (hbci_acc)) > 0)) {
currency = gnc_commodity_table_lookup
(gnc_book_get_commodity_table (gnc_get_current_book ()),
GNC_COMMODITY_NS_ISO, AB_Account_GetCurrency (hbci_acc));
GNC_COMMODITY_NS_CURRENCY, AB_Account_GetCurrency (hbci_acc));
}
gnc_acc = gnc_import_select_account(info->window,

View File

@ -302,7 +302,7 @@ int ofx_proc_transaction_cb(struct OfxTransactionData data, void * transaction_u
{
DEBUG("Currency from libofx: %s",data.account_ptr->currency);
currency = gnc_commodity_table_lookup( gnc_get_current_commodities (),
GNC_COMMODITY_NS_ISO,
GNC_COMMODITY_NS_CURRENCY,
data.account_ptr->currency);
}
else
@ -555,7 +555,7 @@ int ofx_proc_account_cb(struct OfxAccountData data, void * account_user_data)
{
DEBUG("Currency from libofx: %s",data.currency);
default_commodity = gnc_commodity_table_lookup(commodity_table,
GNC_COMMODITY_NS_ISO,
GNC_COMMODITY_NS_CURRENCY,
data.currency);
}
else

View File

@ -2001,7 +2001,7 @@ gnc_ui_qif_import_druid_make(void)
/* set a default currency for new accounts */
gnc_ui_update_commodity_picker(retval->currency_picker,
GNC_COMMODITY_NS_ISO,
GNC_COMMODITY_NS_CURRENCY,
gnc_commodity_get_printname
(gnc_default_currency()));

View File

@ -184,7 +184,7 @@
(default-currency
(gnc:commodity-table-find-full
(gnc:book-get-commodity-table (gnc:get-current-book))
GNC_COMMODITY_NS_ISO default-currency-name))
GNC_COMMODITY_NS_COMMODITY default-currency-name))
(sorted-accounts-list '())
(markable-xtns '())
(sorted-qif-files-list