[Gossip-dev] re-design of new account assistant

Xavier Claessens xclaesse at gmail.com
Wed Sep 27 17:31:22 CEST 2006


Le mercredi 27 septembre 2006 à 16:21 +0200, Mikael Hallendal a écrit :
> Xavier Claessens wrote:
> 
> Hi,
> 
> Sorry for not replying to this the first round. Agree that it makes
> sense to work on this on HEAD rather than the Telepathy branch as it
> would be useful right away and even if we don't switch to Telepathy in
> the future.
> 
> >> For add-account I have some implementation questions. We want one
> >> GtkWidget for each known protocol plus one for unknown. Those widgets
> >> must be used in the GtkAssistant AND in the account-dialog to avoid code
> >> duplications. How to implement that using Glade ? What I have in mind
> >> (but not sure it's the right way):
> >>
> >>   - For each GtkWidget we needed, making a GtkWindow containing it in
> >> the glade.
> >>
> >>   - A new Class GossipAddAccount inheriting from GtkWidget (or
> >> GtkContainer, like that it can contain the GtkWidget readed from the
> >> glade). We can put this object in a page of the GtkAssistant and it
> >> provides a signal like "complete" which says when information are filled
> >> by the user. It will also keep a GHashTable with pairs param_name and
> >> value. And having a function gossip_add_account_param_foreach() like
> >> that we can get values filled by the user and put it in the
> >> GossipAccount.
> 
> I don't think GossipAddAccount is the best of names since it would be
> used for editing an account as well. It doesn't have to inherit a
> GtkWidget but could just return a container containing all the widgets
> (hbox/vbox/table) from the _new function.
> 
> Ie, for example:
> 
> GtkWidget *  gossip_account_settings_icq_new (...);
> 
> Depends a bit if you think we would need common properties/signals (such
> as account-updated) on all settings widgets.
> 
> I would probably go with subclassing GObject and have a "get_widget"
> function on it though.
> 
> Best Regards,
>   Mikael Hallendal

Ok, so I'll make a subclass of GObject named GossipAccountSettings with
a _get_widget() function to return the container that can be added to
the UI. Classes like GossipAccountSettingsMSN can inherit from it if
needed.

I'll post my work once I've something working :-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Ceci est une partie de message
	=?ISO-8859-1?Q?num=E9riquement?= =?ISO-8859-1?Q?_sign=E9e?=
Url : http://lists.imendio.com/pipermail/gossip-dev/attachments/20060927/60d3fabc/attachment.pgp


More information about the Gossip-dev mailing list