aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/importers
diff options
context:
space:
mode:
Diffstat (limited to 'calendar/importers')
-rw-r--r--calendar/importers/icalendar-importer.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/calendar/importers/icalendar-importer.c b/calendar/importers/icalendar-importer.c
index 4d8657df5b..3cda9da6ac 100644
--- a/calendar/importers/icalendar-importer.c
+++ b/calendar/importers/icalendar-importer.c
@@ -1407,25 +1407,20 @@ static icaltimezone *
get_users_timezone (void)
{
/* more or less copy&paste of calendar_config_get_icaltimezone */
- EShell *shell;
- EShellSettings *shell_settings;
+ GSettings *settings;
icaltimezone *zone = NULL;
gchar *location;
- /* FIXME Pass this in. */
- shell = e_shell_get_default ();
- shell_settings = e_shell_get_shell_settings (shell);
+ settings = g_settings_new ("org.gnome.evolution.calendar");
- if (e_shell_settings_get_boolean (shell_settings, "cal-use-system-timezone")) {
+ if (g_settings_get_boolean (settings, "use-system-timezone")) {
location = e_cal_util_get_system_timezone_location ();
} else {
- GSettings *settings = g_settings_new ("org.gnome.evolution.calendar");
-
location = g_settings_get_string (settings, "timezone");
-
- g_object_unref (settings);
}
+ g_object_unref (settings);
+
if (location) {
zone = icaltimezone_get_builtin_timezone (location);