GNOME Bugzilla – Bug 652669
refactor account creation
Last modified: 2012-02-16 16:44:55 UTC
Created attachment 189991 [details] flowchart of new design Empathy currently has two modes for accounts creation: - account assistant -- only run if you have no accounts, uses simple dialogs - add button in empathy-accounts -- uses advanced dialogs This is asymmetrical and weird. Account creation should always follow the same path. Instead we should remove the assistant. And replace it with a number of slideout dialogs: - one to import accounts from Pidgin -- if there are no accounts - one to set up People Nearby -- if there are no accounts - one to add an account If the user clicks add, then the simple 'Add Account' slideout should come up. Once you've set up the details it returns back to the empathy-accounts dialog to watch it connecting.
Let's finish bug #652670 first.
So creating an account would always go to an assistant, but does editing an account change compared to what we have now?
Could you please define "a number of slideout dialogs", that looks like the definition of an assistant to me... Or do you mean popup an modal GtkDialog and when closing it, popup the next one, until all steps are done? This looks like an original way of doing an assistant, I don't think I would like that myself tbh. It means you won't be able to cancel all steps at once, you must go to through all steps first. Maybe some mockups would help.
I drew mockups in my notebook. I'll scan them in.
Danielle, ping
This branch was getting pretty big so I splitted it a bit: bug #670201 and bug #670203
Created attachment 207764 [details] [review] accounts-dialog: display the import dialog if there is no account This is the first step of merging the accounts-dialog and assistant.
Created attachment 207765 [details] [review] add empathy-local-xmpp-assistant-widget All of this is duplicated code from empathy-account-assistant and empathy-auto-salut-account-helper but those are going away so I didn't bother refactoring them.
Created attachment 207766 [details] [review] Move should_create_salut_account to local-xmpp-assistant-widget
Created attachment 207767 [details] [review] accounts-dialog: suggest to create a salut account
Created attachment 207768 [details] [review] empathy-accounts: remove --assistant option It was only used when hacking on the accounts assistant which is going away.
Created attachment 207769 [details] [review] Stop using the accounts assistant Its features have been re-implemented in empathy-accounts-dialog. Thanks to Danielle for this new design.
Created attachment 207770 [details] [review] Remove empathy-account-assistant DIE DIE DIE!!!
Created attachment 207771 [details] [review] remove empathy-auto-salut-account-helper It was used only by the accounts assistant
Review of attachment 207764 [details] [review]: Looks fine.
Review of attachment 207765 [details] [review]: I'm basically going to believe you when you say that this works. :) ::: libempathy-gtk/empathy-local-xmpp-assistant-widget.c @@ +36,3 @@ +#include <libempathy/empathy-debug.h> + +G_DEFINE_TYPE (EmpathyLocalXmppAssistantWidget,\ You don't need this backslash. @@ +187,3 @@ + + G_OBJECT_CLASS (empathy_local_xmpp_assistant_widget_parent_class)-> + constructed (object); You should chain up at the beginning of constructed, not at the end.
Review of attachment 207766 [details] [review]: Okay.
Review of attachment 207765 [details] [review]: ::: libempathy-gtk/empathy-local-xmpp-assistant-widget.c @@ +36,3 @@ +#include <libempathy/empathy-debug.h> + +G_DEFINE_TYPE (EmpathyLocalXmppAssistantWidget,\ removed. @@ +187,3 @@ + + G_OBJECT_CLASS (empathy_local_xmpp_assistant_widget_parent_class)-> + constructed (object); done.
Created attachment 207773 [details] [review] add empathy-local-xmpp-assistant-widget All of this is duplicated code from empathy-account-assistant and empathy-auto-salut-account-helper but those are going away so I didn't bother refactoring them.
Review of attachment 207767 [details] [review]: The code looks fine… but as discussed on IRC the dialog does not. :) ::: src/empathy-accounts-dialog.c @@ +2081,3 @@ + gtk_window_set_modal (GTK_WINDOW (dialog), TRUE); + + gint response; As on IRC: change this to Skip.
Review of attachment 207768 [details] [review]: Sure.
Review of attachment 207769 [details] [review]: Looks fine.
Review of attachment 207770 [details] [review]: There's not much to review here. If you think it's clear enough how to add a second account after you've created one from the first automatic slide-out dialog, then fine. That's the main thing the assistant did that I think this whole change loses us: it made it very obvious how to set up more than one account (admittedly only on the first run).
Review of attachment 207771 [details] [review]: ++
Review of attachment 207773 [details] [review]: ++
Created attachment 207777 [details] [review] salut-dialog: use 'Skip' instead of 'Ignore'
Created attachment 207778 [details] [review] local-xmpp-assistant-widget: inherit from a GtkGrid It simplifies widgets packing.
Created attachment 207779 [details] [review] widget-local-xmpp: expand the entry fields We want them to take all the space available.
Created attachment 207780 [details] [review] move the second part of the message at the end of the widget I rephrased it as well per Will's suggestion.
Created attachment 207781 [details] [review] use the 48x48 version of the local-xmpp icon We don't have to scale up the icon any more and it looks good as it.
Review of attachment 207778 [details] [review]: Looks fine.
Review of attachment 207779 [details] [review]: Surely you only want hexpand?
Review of attachment 207780 [details] [review]: Looks fine.
Review of attachment 207781 [details] [review]: Looks good.
(In reply to comment #32) > Review of attachment 207779 [details] [review]: > > Surely you only want hexpand? Right; changed.
Attachment 207764 [details] pushed as 692672a - accounts-dialog: display the import dialog if there is no account Attachment 207766 [details] pushed as fe9e5a3 - Move should_create_salut_account to local-xmpp-assistant-widget Attachment 207767 [details] pushed as 1dc8418 - accounts-dialog: suggest to create a salut account Attachment 207768 [details] pushed as db89425 - empathy-accounts: remove --assistant option Attachment 207769 [details] pushed as 6fc913d - Stop using the accounts assistant Attachment 207770 [details] pushed as a266c22 - Remove empathy-account-assistant Attachment 207771 [details] pushed as 208dcb1 - remove empathy-auto-salut-account-helper Attachment 207773 [details] pushed as fea6df6 - add empathy-local-xmpp-assistant-widget Attachment 207777 [details] pushed as 3e85f81 - salut-dialog: use 'Skip' instead of 'Ignore' Attachment 207778 [details] pushed as 1b0f008 - local-xmpp-assistant-widget: inherit from a GtkGrid Attachment 207779 [details] pushed as 4e2b90e - widget-local-xmpp: expand the entry fields Attachment 207780 [details] pushed as cc16ff0 - move the second part of the message at the end of the widget Attachment 207781 [details] pushed as 7cd8231 - use the 48x48 version of the local-xmpp icon