Commit f2832e7d authored by Tristan Matthews's avatar Tristan Matthews

* #9490: gnome: fixed account add behaviour

parent 454d6502
......@@ -142,13 +142,6 @@ static void edit_account_cb(GtkButton *button UNUSED, gpointer data)
g_free(selected_accountID);
}
static void add_account_cb(void)
{
account_t *new_account = create_default_account();
account_list_add(new_account);
run_account_dialog(new_account->accountID);
}
static void account_store_add(GtkTreeIter *iter, account_t *account)
{
const gchar *enabled = account_lookup(account, ACCOUNT_ENABLED);
......@@ -165,10 +158,12 @@ static void account_store_add(GtkTreeIter *iter, account_t *account)
}
/**
* Fills the treelist with accounts
* Fills the treelist with accounts, should be called whenever the account
* list is modified.
*/
void account_store_fill()
static void account_store_fill()
{
RETURN_IF_NULL(account_list_dialog, "No account dialog");
gtk_list_store_clear(account_store);
......@@ -195,6 +190,14 @@ void account_store_fill()
}
}
static void add_account_cb(void)
{
account_t *new_account = create_default_account();
account_list_add(new_account);
run_account_dialog(new_account->accountID);
account_store_fill();
}
/**
* Call back when the user click on an account in the list
*/
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment