From 0e484889645877be5b8b22014202cf4ceaf7c846 Mon Sep 17 00:00:00 2001 From: Christopher Lam Date: Thu, 13 Jul 2023 22:05:41 +0800 Subject: [PATCH] [import-account-matcher.cpp] convert to cpp --- gnucash/import-export/CMakeLists.txt | 2 +- ...import-account-matcher.c => import-account-matcher.cpp} | 7 +++---- po/POTFILES.in | 2 +- 3 files changed, 5 insertions(+), 6 deletions(-) rename gnucash/import-export/{import-account-matcher.c => import-account-matcher.cpp} (98%) diff --git a/gnucash/import-export/CMakeLists.txt b/gnucash/import-export/CMakeLists.txt index a7a6510523..739dbf0489 100644 --- a/gnucash/import-export/CMakeLists.txt +++ b/gnucash/import-export/CMakeLists.txt @@ -14,7 +14,7 @@ add_subdirectory(qif-imp) set (generic_import_SOURCES - import-account-matcher.c + import-account-matcher.cpp import-commodity-matcher.cpp import-backend.cpp import-format-dialog.c diff --git a/gnucash/import-export/import-account-matcher.c b/gnucash/import-export/import-account-matcher.cpp similarity index 98% rename from gnucash/import-export/import-account-matcher.c rename to gnucash/import-export/import-account-matcher.cpp index 0795d52944..4179e27d18 100644 --- a/gnucash/import-export/import-account-matcher.c +++ b/gnucash/import-export/import-account-matcher.cpp @@ -368,10 +368,9 @@ Account * gnc_import_select_account(GtkWidget *parent, if (account_online_id_value) { AccountOnlineMatch match = {NULL, 0, account_online_id_value}; - retval = - gnc_account_foreach_descendant_until(gnc_get_current_root_account (), - test_acct_online_id_match, - (void*)&match); + retval = static_cast(gnc_account_foreach_descendant_until (gnc_get_current_root_account (), + test_acct_online_id_match, + (void*)&match)); if (!retval && match.count == 1 && new_account_default_type == ACCT_TYPE_NONE) retval = match.partial_match; diff --git a/po/POTFILES.in b/po/POTFILES.in index 7c9ffa4a51..fd6e3ea360 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in @@ -346,7 +346,7 @@ gnucash/import-export/csv-imp/gnc-tokenizer-fw.cpp gnucash/import-export/customer-import/dialog-customer-import.c gnucash/import-export/customer-import/dialog-customer-import-gui.c gnucash/import-export/customer-import/gnc-plugin-customer-import.c -gnucash/import-export/import-account-matcher.c +gnucash/import-export/import-account-matcher.cpp gnucash/import-export/import-backend.cpp gnucash/import-export/import-commodity-matcher.cpp gnucash/import-export/import-format-dialog.c