Re: [gnome-network]PATCH for Profiles etc. with GConf implementation



On Wed, 2004-01-14 at 22:01 +0100, Ulrich Neumann wrote:
> Hi,
> 
> attached is the patch again. Now the profiles are stored in GConf as a
> list.
> 
> As mentioned you need to use all three files together.
> gnome-remote-shell.h is a new file, the other files patch
> gnome-remote-shell.c and gnome-remote-shell.glade.
> 
we're almost there:

> +	gtk_list_store_append (list_store, &iter);
> +	gtk_list_store_set (list_store, &iter,
> +				0, addhost,
> +				1, adduser,
> +				2, addport,
> +				-1);
> +
I think we should store the changes in Gconf immediately, to have new entries
or removed entries immediately show up in the configuration.

> +	gtk_tree_selection_set_mode(selection, GTK_SELECTION_SINGLE);
> +	if (gtk_tree_selection_get_selected(selection, &model, &iter)) {
> +		gtk_list_store_remove(list_store, &iter);
>
here, the same, save changes to GConf immediately. you can move the
treeview saving code from window_destroyed_cb into its own function, and
thus call it from these 2 places.

> +/*
> + * Read list from .gmoe-remote-shell.profiles at startup
> + */
> +int
> +profile_from_file (void)
> +{
> 
why do we need this for, if we store profiles in GConf?

cheers




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]