diff options
author | Charles Kerr <charles.kerr@canonical.com> | 2013-05-06 13:51:27 -0700 |
---|---|---|
committer | Charles Kerr <charles.kerr@canonical.com> | 2013-05-06 13:51:27 -0700 |
commit | cc92756aaa57060539f57ce92d41ded0966b92d1 (patch) | |
tree | 34552c222f1caa7cd9484f36057bc4a82a3385b5 /src/datetime-service.c | |
parent | c6db70370a10da3ac86dd5fc979aad214b8e246b (diff) | |
download | ayatana-indicator-datetime-cc92756aaa57060539f57ce92d41ded0966b92d1.tar.gz ayatana-indicator-datetime-cc92756aaa57060539f57ce92d41ded0966b92d1.tar.bz2 ayatana-indicator-datetime-cc92756aaa57060539f57ce92d41ded0966b92d1.zip |
readability changes suggested by lars
Diffstat (limited to 'src/datetime-service.c')
-rw-r--r-- | src/datetime-service.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/datetime-service.c b/src/datetime-service.c index a8f941a..7b7c2db 100644 --- a/src/datetime-service.c +++ b/src/datetime-service.c @@ -1256,16 +1256,15 @@ on_use_geoclue_changed_cb (GSettings *settings, gchar *key G_GNUC_UNUSED, gpointer user_data G_GNUC_UNUSED) { - const gboolean using = geo_location != NULL; - const gboolean should_use = g_settings_get_boolean (conf, "show-auto-detected-location"); + const gboolean use_geoclue = g_settings_get_boolean (conf, "show-auto-detected-location"); - if (using && !should_use) + if (geo_location && !use_geoclue) { g_signal_handlers_disconnect_by_func (geo_location, update_location_menu_items, 0); g_clear_object (&geo_location); update_location_menu_items (); } - else if (should_use && !using) + else if (use_geoclue && !geo_location) { geo_location = indicator_datetime_location_geoclue_new (); g_signal_connect (geo_location, "notify::timezone", |