diff options
author | Rodrigo Moya <rodrigo@gnome-db.org> | 2011-10-13 23:00:14 +0800 |
---|---|---|
committer | Rodrigo Moya <rodrigo@gnome-db.org> | 2011-10-13 23:00:14 +0800 |
commit | b436b8468346c384edc6bde0f24b2ac0ce657e00 (patch) | |
tree | c7ffb256666864a66742c1edc349a4f2150f382f | |
parent | d4e8e2f809d4da7dd5ac0b53a7900e5bd39777f9 (diff) | |
download | gsoc2013-evolution-b436b8468346c384edc6bde0f24b2ac0ce657e00.tar.gz gsoc2013-evolution-b436b8468346c384edc6bde0f24b2ac0ce657e00.tar.zst gsoc2013-evolution-b436b8468346c384edc6bde0f24b2ac0ce657e00.zip |
Migrate Contact Editor to GSettings
-rw-r--r-- | addressbook/gui/contact-editor/e-contact-editor.c | 18 | ||||
-rw-r--r-- | data/evolution.convert | 27 | ||||
-rw-r--r-- | data/org.gnome.evolution.addressbook.gschema.xml.in | 5 |
3 files changed, 23 insertions, 27 deletions
diff --git a/addressbook/gui/contact-editor/e-contact-editor.c b/addressbook/gui/contact-editor/e-contact-editor.c index 28b5b636fe..9ad6fc0612 100644 --- a/addressbook/gui/contact-editor/e-contact-editor.c +++ b/addressbook/gui/contact-editor/e-contact-editor.c @@ -2302,26 +2302,16 @@ set_address_label (EContact *contact, { gchar *address_label = NULL; gboolean format_address; - GConfClient *client; - GConfValue *value; + GSettings *settings; if (!address) { e_contact_set (contact, field, NULL); return; } - - client = gconf_client_get_default (); - value = gconf_client_get (client, - "/apps/evolution/addressbook/display/address_formatting", NULL); - g_object_unref (client); - - if (value) { - format_address = gconf_value_get_bool (value); - gconf_value_free (value); - } else { - format_address = TRUE; - } + settings = g_settings_new ("org.gnome.evolution.addressbook"); + format_address = g_settings_get_boolean (settings, "address-formatting"); + g_object_unref (settings); if (format_address) { address_label = eab_format_address (contact, diff --git a/data/evolution.convert b/data/evolution.convert index 452ea39479..075a24a579 100644 --- a/data/evolution.convert +++ b/data/evolution.convert @@ -3,33 +3,34 @@ version = /apps/evolution/version last-upgraded-version = /apps/evolution/last_version [org.gnome.evolution.shell] -skip-warning-dialog = /apps/evolution/shell/skip_warning_dialog attachment-view = /apps/evolution/shell/attachment_view +buttons-visible = /apps/evolution/shell/view_defaults/buttons_visible +buttons-style = /apps/evolution/shell/view_defaults/buttons_style +default-component-id = /apps/evolution/shell/view_defaults/component_id +express-mode = /apps/evolution/shell/express_mode file-chooser-folder = /apps/evolution/shell/file_chooser_folder -start-offline = /apps/evolution/shell/start_offline +folder-bar-width = /apps/evolution/shell/view_defaults/folder_bar/width folder-paths = /apps/evolution/shell/offline/folder_paths -express-mode = /apps/evolution/shell/express_mode +sidebar-visible = /apps/evolution/shell/view_defaults/sidebar_visible +skip-warning-dialog = /apps/evolution/shell/skip_warning_dialog +start-offline = /apps/evolution/shell/start_offline +statusbar-visible = /apps/evolution/shell/view_defaults/statusbar_visible +toolbar-visible = /apps/evolution/shell/view_defaults/toolbar_visible window-y = /apps/evolution/shell/view_defaults/window_y window-x = /apps/evolution/shell/view_defaults/window_x window-width = /apps/evolution/shell/view_defaults/window_width window-height = /apps/evolution/shell/view_defaults/window_height window-maximized = /apps/evolution/shell/view_defaults/window_maximized -buttons-visible = /apps/evolution/shell/view_defaults/buttons_visible -buttons-style = /apps/evolution/shell/view_defaults/buttons_style -toolbar-visible = /apps/evolution/shell/view_defaults/toolbar_visible -sidebar-visible = /apps/evolution/shell/view_defaults/sidebar_visible -statusbar-visible = /apps/evolution/shell/view_defaults/statusbar_visible -default-component-id = /apps/evolution/shell/view_defaults/component_id -folder-bar-width = /apps/evolution/shell/view_defaults/folder_bar/width [org.gnome.evolution.addressbook] +address-formatting = /apps/evolution/addressbook/display/address_formatting completion-minimum-query-length = /apps/evolution/addressbook/completion/minimum_query_length completion-show-address = /apps/evolution/addressbook/completion/show_address -select-names-last-used-uri = /apps/evolution/addressbook/select_names/last_used_uri -layout = /apps/evolution/addressbook/display/layout hpane-position = /apps/evolution/addressbook/display/hpane_position -vpane-position = /apps/evolution/addressbook/display/vpane_position +layout = /apps/evolution/addressbook/display/layout +select-names-last-used-uri = /apps/evolution/addressbook/select_names/last_used_uri show-preview = /apps/evolution/addressbook/display/show_preview +vpane-position = /apps/evolution/addressbook/display/vpane_position [org.gnome.evolution.calendar] audio-dir = /apps/evolution/calendar/audio_dir diff --git a/data/org.gnome.evolution.addressbook.gschema.xml.in b/data/org.gnome.evolution.addressbook.gschema.xml.in index f4f1a556c7..11efc0c2af 100644 --- a/data/org.gnome.evolution.addressbook.gschema.xml.in +++ b/data/org.gnome.evolution.addressbook.gschema.xml.in @@ -1,5 +1,10 @@ <schemalist> <schema gettext-domain="evolution" id="org.gnome.evolution.addressbook" path="/org/gnome/evolution/addressbook/"> + <key name="address-formatting" type="b"> + <default>false</default> + <_summary>Enable address formatting</_summary> + <_description>Whether addresses should be formatted according to standard in their destination country</_description> + </key> <key name="completion-minimum-query-length" type="i"> <default>3</default> <_summary>Autocomplete length</_summary> |