aboutsummaryrefslogtreecommitdiffstats
path: root/shell/e-shell-config-autocompletion.c
diff options
context:
space:
mode:
authorEttore Perazzoli <ettore@src.gnome.org>2002-11-20 05:25:37 +0800
committerEttore Perazzoli <ettore@src.gnome.org>2002-11-20 05:25:37 +0800
commit8b3091dea7eb0e975f40f8cb7ffaa8bb8a36ffdb (patch)
treeeebbfb8c33da954ced2f77ab4cfcafaf9902342f /shell/e-shell-config-autocompletion.c
parent6f1d5b31351a2e4d31cd92a3856fd98e9dc2a6af (diff)
downloadgsoc2013-evolution-8b3091dea7eb0e975f40f8cb7ffaa8bb8a36ffdb.tar
gsoc2013-evolution-8b3091dea7eb0e975f40f8cb7ffaa8bb8a36ffdb.tar.gz
gsoc2013-evolution-8b3091dea7eb0e975f40f8cb7ffaa8bb8a36ffdb.tar.bz2
gsoc2013-evolution-8b3091dea7eb0e975f40f8cb7ffaa8bb8a36ffdb.tar.lz
gsoc2013-evolution-8b3091dea7eb0e975f40f8cb7ffaa8bb8a36ffdb.tar.xz
gsoc2013-evolution-8b3091dea7eb0e975f40f8cb7ffaa8bb8a36ffdb.tar.zst
gsoc2013-evolution-8b3091dea7eb0e975f40f8cb7ffaa8bb8a36ffdb.zip
Disabled for now.
* main.c (upgrade_from_1_0_if_needed): Disabled for now. * e-shell-startup-wizard.c: Removed member config_listener from struct SWData. (e_shell_startup_wizard_create): Updated accordingly, just use GConf, checking the /apps/evolution/mail/account-list key. (finish_func): Use GConf. * e-shell-config-default-folders.c: Removed member config_listener in struct EvolutionDefaultFolderConfig. (e_shell_config_default_folders_create_widget): Do not initialize here. GConfified the paths. (config_control_destroy_notify): No unref of the config_listener anymore. (config_control_apply_cb): Use GConf. (setup_folder_selector): Likewise. * e-shell-config-autocompletion.c: Removed member config_listener from EvolutionAutocompletionConfig. (config_control_destroy_notify): Do not unref. (config_control_apply_callback): Use a GConfClient. * e-folder-list.c (e_folder_list_init): Add missing cast. * main.c (show_development_warning): Use GConf. * e-setup.c (e_setup_check_config): Removed arg @listener. GConfified. * e-shell-view.c (e_shell_view_save_defaults): New. (e_shell_view_save_settings): Removed. (e_shell_view_load_settings): Removed. (setup_defaults): New helper function. (e_shell_view_construct): New arg @uri. (e_shell_view_new): New arg @uri. * e-shell.c: Removed member config_listener in struct EShellPrivate. (impl_dispose): Do not unref. (init): Do not initialize. (get_config_start_offline): New helper function. (e_shell_construct): Use this to get the startup mode in case E_SHELL_STARTUP_LINE_MODE_CONFIG. (save_misc_settings): Changed to use GConfClient instead of EConfigListener. (e_shell_create_view_from_settings): Removed. (e_shell_restore_from_settings): Removed. (e_shell_get_config_listener): Removed. (e_shell_disconnect_db): Removed. (parse_default_uri): Use GConf. * main.c (idle_cb): Simplified the logic here. Always assume that the view will be created with the default folder open by just using e_shell_create_view(). svn path=/trunk/; revision=18844
Diffstat (limited to 'shell/e-shell-config-autocompletion.c')
-rw-r--r--shell/e-shell-config-autocompletion.c21
1 files changed, 13 insertions, 8 deletions
diff --git a/shell/e-shell-config-autocompletion.c b/shell/e-shell-config-autocompletion.c
index b3b72bb954..4cb498dba1 100644
--- a/shell/e-shell-config-autocompletion.c
+++ b/shell/e-shell-config-autocompletion.c
@@ -38,13 +38,14 @@
#include <gtk/gtkwidget.h>
#include <gtk/gtksignal.h>
+#include <gconf/gconf-client.h>
+
typedef struct {
EvolutionConfigControl *config_control;
GtkWidget *control_widget;
- EConfigListener *config_listener;
EvolutionShellClient *shell_client;
} EvolutionAutocompletionConfig;
@@ -62,7 +63,6 @@ config_control_destroy_notify (void *data,
EvolutionAutocompletionConfig *ac = (EvolutionAutocompletionConfig *) data;
g_object_unref (ac->shell_client);
- g_object_unref (ac->config_listener);
g_free (ac);
}
@@ -72,11 +72,16 @@ static void
config_control_apply_callback (EvolutionConfigControl *config_control,
EvolutionAutocompletionConfig *ac)
{
+ GConfClient *client;
char *xml;
+ client = gconf_client_get_default ();
+
xml = e_folder_list_get_xml (E_FOLDER_LIST (ac->control_widget));
- e_config_listener_set_string (ac->config_listener, "/Addressbook/Completion/uris", xml);
+ gconf_client_set_string (client, "/apps/evolution/addressbook/completion/uris", xml, NULL);
g_free (xml);
+
+ g_object_unref (client);
}
GtkWidget *
@@ -84,21 +89,21 @@ e_shell_config_autocompletion_create_widget (EShell *shell, EvolutionConfigContr
{
GNOME_Evolution_Shell shell_dup;
EvolutionAutocompletionConfig *ac;
- char *xml;
CORBA_Environment ev;
+ GConfClient *client;
static const char *possible_types[] = { "contacts/*", NULL };
+ char *xml;
ac = g_new0 (EvolutionAutocompletionConfig, 1);
- ac->config_listener = e_config_listener_new ();
CORBA_exception_init (&ev);
shell_dup = CORBA_Object_duplicate (BONOBO_OBJREF (shell), &ev);
ac->shell_client = evolution_shell_client_new (shell_dup);
- xml = e_config_listener_get_string_with_default (ac->config_listener,
- "/Addressbook/Completion/uris",
- NULL, NULL);
+ client = gconf_client_get_default ();
+ xml = gconf_client_get_string (client, "/apps/evolution/addressbook/completion/uris", NULL);
+ g_object_unref (client);
ac->control_widget = e_folder_list_new (ac->shell_client, xml);
g_free (xml);