diff options
author | Stefano Karapetsas <[email protected]> | 2012-09-05 19:50:04 +0200 |
---|---|---|
committer | Stefano Karapetsas <[email protected]> | 2012-09-05 19:50:04 +0200 |
commit | 4ce75a73f8a69f906a784a7704be7891e7519d81 (patch) | |
tree | 8e4694283757046632b763131b18047a8005740c /libcaja-private/caja-icon-container.c | |
parent | 1a64f79e50328465453567515ddd62c3ea394662 (diff) | |
download | caja-4ce75a73f8a69f906a784a7704be7891e7519d81.tar.bz2 caja-4ce75a73f8a69f906a784a7704be7891e7519d81.tar.xz |
convert desktop preferences to gsettings
Diffstat (limited to 'libcaja-private/caja-icon-container.c')
-rw-r--r-- | libcaja-private/caja-icon-container.c | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/libcaja-private/caja-icon-container.c b/libcaja-private/caja-icon-container.c index fa9651b7..787c1785 100644 --- a/libcaja-private/caja-icon-container.c +++ b/libcaja-private/caja-icon-container.c @@ -4456,6 +4456,9 @@ finalize (GObject *object) g_signal_handlers_disconnect_by_func (caja_icon_view_preferences, text_ellipsis_limit_changed_container_callback, object); + g_signal_handlers_disconnect_by_func (caja_desktop_preferences, + text_ellipsis_limit_changed_container_callback, + object); g_hash_table_destroy (details->icon_set); details->icon_set = NULL; @@ -6202,9 +6205,10 @@ caja_icon_container_constructor (GType type, container = CAJA_ICON_CONTAINER (object); if (caja_icon_container_get_is_desktop (container)) { - eel_preferences_add_callback_while_alive (CAJA_PREFERENCES_DESKTOP_TEXT_ELLIPSIS_LIMIT, - text_ellipsis_limit_changed_container_callback, - container, G_OBJECT (container)); + g_signal_connect_swapped (caja_desktop_preferences, + "changed::" CAJA_PREFERENCES_DESKTOP_TEXT_ELLIPSIS_LIMIT, + G_CALLBACK (text_ellipsis_limit_changed_container_callback), + container); } else { @@ -6850,7 +6854,7 @@ desktop_text_ellipsis_limit_changed_callback (gpointer callback_data) { int pref; - pref = eel_preferences_get_integer (CAJA_PREFERENCES_DESKTOP_TEXT_ELLIPSIS_LIMIT); + pref = g_settings_get_int (caja_desktop_preferences, CAJA_PREFERENCES_DESKTOP_TEXT_ELLIPSIS_LIMIT); desktop_text_ellipsis_limit = pref; } @@ -6902,9 +6906,10 @@ caja_icon_container_init (CajaIconContainer *container) NULL); text_ellipsis_limit_changed_callback (NULL); - eel_preferences_add_callback (CAJA_PREFERENCES_DESKTOP_TEXT_ELLIPSIS_LIMIT, - desktop_text_ellipsis_limit_changed_callback, - NULL); + g_signal_connect_swapped (caja_icon_view_preferences, + "changed::" CAJA_PREFERENCES_DESKTOP_TEXT_ELLIPSIS_LIMIT, + G_CALLBACK (desktop_text_ellipsis_limit_changed_callback), + NULL); desktop_text_ellipsis_limit_changed_callback (NULL); setup_prefs = TRUE; |