diff options
author | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2010-01-22 22:15:48 +0800 |
---|---|---|
committer | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2010-01-25 22:13:40 +0800 |
commit | 001c1043c2670229dc379edf90d6f9041371d0d7 (patch) | |
tree | c0fbb1514cc906f55d6d450f5f97d30f86670331 /src/empathy-account-assistant.c | |
parent | 3bda80255069253fcb801673c3c81c8d1cd4a67e (diff) | |
download | gsoc2013-empathy-001c1043c2670229dc379edf90d6f9041371d0d7.tar gsoc2013-empathy-001c1043c2670229dc379edf90d6f9041371d0d7.tar.gz gsoc2013-empathy-001c1043c2670229dc379edf90d6f9041371d0d7.tar.bz2 gsoc2013-empathy-001c1043c2670229dc379edf90d6f9041371d0d7.tar.lz gsoc2013-empathy-001c1043c2670229dc379edf90d6f9041371d0d7.tar.xz gsoc2013-empathy-001c1043c2670229dc379edf90d6f9041371d0d7.tar.zst gsoc2013-empathy-001c1043c2670229dc379edf90d6f9041371d0d7.zip |
Fix account creation regression
Each time we add a new account, a new page is added to the assistant. So
checking if id equal PAGE_ENTER_CREATE is not enough as the next pages will
have an id greater than that.
Diffstat (limited to 'src/empathy-account-assistant.c')
-rw-r--r-- | src/empathy-account-assistant.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/empathy-account-assistant.c b/src/empathy-account-assistant.c index 964b69154..042e433f5 100644 --- a/src/empathy-account-assistant.c +++ b/src/empathy-account-assistant.c @@ -849,12 +849,17 @@ impl_signal_apply (GtkAssistant *assistant) current_page = gtk_assistant_get_current_page (assistant); - if (current_page == PAGE_ENTER_CREATE) + if (current_page == PAGE_SALUT) + { + if (priv->create_salut_account) + account_assistant_apply_account_and_finish (self, priv->salut_settings); + return; + } + + if (current_page >= PAGE_ENTER_CREATE) account_assistant_apply_account_and_finish (self, priv->settings); else if (current_page == PAGE_IMPORT) empathy_import_widget_add_selected_accounts (priv->iw); - else if (current_page == PAGE_SALUT && priv->create_salut_account) - account_assistant_apply_account_and_finish (self, priv->salut_settings); } static void @@ -873,7 +878,7 @@ impl_signal_prepare (GtkAssistant *assistant, current_idx = gtk_assistant_get_current_page (assistant); - if (current_idx == PAGE_ENTER_CREATE) + if (current_idx >= PAGE_ENTER_CREATE && current_idx != PAGE_SALUT) { if (!priv->enter_create_forward) { |