Change source files gnc-ab-utils.* for spaces and tabs

This commit is contained in:
Robert Fewell 2022-07-29 10:49:32 +01:00
parent edf000f4cf
commit 6cad1d16af
2 changed files with 397 additions and 392 deletions

View File

@ -72,12 +72,12 @@ static Account *gnc_ab_accinfo_to_gnc_acc(GtkWidget *parent,
AB_IMEXPORTER_ACCOUNTINFO *account_info);
static Account *gnc_ab_txn_to_gnc_acc (GtkWidget *parent,
const AB_TRANSACTION *transaction);
static const AB_TRANSACTION *txn_transaction_cb(
const AB_TRANSACTION *element, gpointer user_data);
static AB_IMEXPORTER_ACCOUNTINFO *txn_accountinfo_cb(
AB_IMEXPORTER_ACCOUNTINFO *element, gpointer user_data);
static AB_IMEXPORTER_ACCOUNTINFO *bal_accountinfo_cb(
AB_IMEXPORTER_ACCOUNTINFO *element, gpointer user_data);
static const AB_TRANSACTION *txn_transaction_cb (const AB_TRANSACTION *element,
gpointer user_data);
static AB_IMEXPORTER_ACCOUNTINFO *txn_accountinfo_cb (AB_IMEXPORTER_ACCOUNTINFO *element,
gpointer user_data);
static AB_IMEXPORTER_ACCOUNTINFO *bal_accountinfo_cb (AB_IMEXPORTER_ACCOUNTINFO *element,
gpointer user_data);
struct _GncABImExContextImport
{
@ -644,8 +644,7 @@ gnc_ab_trans_to_gnc(const AB_TRANSACTION *ab_trans, Account *gnc_acc)
/* Set the transaction number or split action field based on book option.
* We use the "customer reference", if there is one. */
custref = AB_Transaction_GetCustomerReference (ab_trans);
if (custref && *custref
&& g_ascii_strncasecmp(custref, "NONREF", 6) != 0)
if (custref && *custref && g_ascii_strncasecmp (custref, "NONREF", 6) != 0)
gnc_set_num_action (gnc_trans, split, custref, NULL);
/* Set OFX unique transaction ID */
@ -704,8 +703,8 @@ gnc_ab_accinfo_to_gnc_acc(GtkWidget *parent, AB_IMEXPORTER_ACCOUNTINFO *acc_info
bankcode = AB_ImExporterAccountInfo_GetBankCode (acc_info);
accountnumber = AB_ImExporterAccountInfo_GetAccountNumber (acc_info);
online_id = gnc_ab_create_online_id (bankcode, accountnumber);
gnc_acc = gnc_import_select_account(
parent, online_id, 1, AB_ImExporterAccountInfo_GetAccountName(acc_info),
gnc_acc = gnc_import_select_account (parent, online_id, 1,
AB_ImExporterAccountInfo_GetAccountName (acc_info),
NULL, ACCT_TYPE_NONE, NULL, NULL);
if (!gnc_acc)
{
@ -743,8 +742,8 @@ gnc_ab_txn_to_gnc_acc(GtkWidget *parent, const AB_TRANSACTION *transaction)
}
online_id = gnc_ab_create_online_id (bankcode, accountnumber);
gnc_acc = gnc_import_select_account(
parent, online_id, 1, AB_Transaction_GetLocalName(transaction),
gnc_acc = gnc_import_select_account (parent, online_id, 1,
AB_Transaction_GetLocalName (transaction),
NULL, ACCT_TYPE_NONE, NULL, NULL);
if (!gnc_acc)
{
@ -1267,7 +1266,8 @@ gnc_ab_import_context(AB_IMEXPORTER_CONTEXT *context,
if (ab_ail && AB_ImExporterAccountInfo_List_GetCount (ab_ail))
{
if (!(awaiting & IGNORE_TRANSACTIONS))
AB_ImExporterAccountInfo_List_ForEach(ab_ail, txn_accountinfo_cb,
AB_ImExporterAccountInfo_List_ForEach (ab_ail,
txn_accountinfo_cb,
data);
/* populate and display the matching window */
@ -1276,12 +1276,14 @@ gnc_ab_import_context(AB_IMEXPORTER_CONTEXT *context,
/* Check balances */
if (!(awaiting & IGNORE_BALANCES))
AB_ImExporterAccountInfo_List_ForEach(ab_ail, bal_accountinfo_cb,
AB_ImExporterAccountInfo_List_ForEach (ab_ail,
bal_accountinfo_cb,
data);
}
#else
if (!(awaiting & IGNORE_TRANSACTIONS))
AB_ImExporterContext_AccountInfoForEach(context, txn_accountinfo_cb,
AB_ImExporterContext_AccountInfoForEach (context,
txn_accountinfo_cb,
data);
/* populate and display the matching window */
@ -1290,7 +1292,8 @@ gnc_ab_import_context(AB_IMEXPORTER_CONTEXT *context,
/* Check balances */
if (!(awaiting & IGNORE_BALANCES))
AB_ImExporterContext_AccountInfoForEach(context, bal_accountinfo_cb,
AB_ImExporterContext_AccountInfoForEach (context,
bal_accountinfo_cb,
data);
#endif

View File

@ -239,9 +239,11 @@ Transaction *gnc_ab_trans_to_gnc(const AB_TRANSACTION *ab_trans, Account *gnc_ac
* gnc_ab_ieci_get_job_list() must be called and the result freed with
* AB_Job_List2_FreeAll()
*/
GncABImExContextImport *gnc_ab_import_context(
AB_IMEXPORTER_CONTEXT *context, guint awaiting, gboolean execute_txns,
AB_BANKING *api, GtkWidget *parent);
GncABImExContextImport *gnc_ab_import_context (AB_IMEXPORTER_CONTEXT *context,
guint awaiting,
gboolean execute_txns,
AB_BANKING *api,
GtkWidget *parent);
/**
* Extract awaiting from @a data.