diff options
author | Robert Tari <robert@tari.in> | 2021-05-03 13:58:25 +0200 |
---|---|---|
committer | Robert Tari <robert@tari.in> | 2021-05-12 12:20:50 +0200 |
commit | ef73e1d341ecb2a39944bbd7172bda1711958a4d (patch) | |
tree | 7a92002e4c11aa3f8fea8fb84b0bf9f987e6aaf3 | |
parent | 80df555dd96b5a9102453cad9a3da8439a448653 (diff) | |
download | ayatana-ido-ef73e1d341ecb2a39944bbd7172bda1711958a4d.tar.gz ayatana-ido-ef73e1d341ecb2a39944bbd7172bda1711958a4d.tar.bz2 ayatana-ido-ef73e1d341ecb2a39944bbd7172bda1711958a4d.zip |
src/idolocationmenuitem.c: Fix deprecated g_time_zone_new warning.
Fixes AyatanaIndicators/ayatana-ido#30
-rw-r--r-- | src/idolocationmenuitem.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/idolocationmenuitem.c b/src/idolocationmenuitem.c index 8b16807..6999cc1 100644 --- a/src/idolocationmenuitem.c +++ b/src/idolocationmenuitem.c @@ -53,7 +53,12 @@ update_timestamp (IdoLocationMenuItem * self) IdoLocationMenuItemPrivate * priv = ido_location_menu_item_get_instance_private(self); - tz = g_time_zone_new (priv->timezone); + #if GLIB_CHECK_VERSION(2, 68, 0) + tz = g_time_zone_new_identifier (priv->timezone); + #else + tz = g_time_zone_new (priv->timezone); + #endif + if (tz == NULL) tz = g_time_zone_new_local (); date_time = g_date_time_new_now (tz); |