Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 1 | From c582338ef4f33b3dc07a2636340d55b9fb530650 Mon Sep 17 00:00:00 2001 |
| 2 | From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@googlemail.com> |
| 3 | Date: Wed, 17 Feb 2016 00:15:44 +0100 |
| 4 | Subject: [PATCH] clock-time: make change of system's timezone change time for |
| 5 | DEFAULT_TIMEZONE |
| 6 | MIME-Version: 1.0 |
| 7 | Content-Type: text/plain; charset=UTF-8 |
| 8 | Content-Transfer-Encoding: 8bit |
| 9 | |
| 10 | clock_time->timezone is set in clock_time_init so the condition |
| 11 | |
| 12 | 'clock_time->timezone != NULL |
| 13 | |
| 14 | is matching always. |
| 15 | |
| 16 | Tested by selecting seconds displayed (-> quick update) and changing timezone. |
| 17 | |
| 18 | Upstream-Status: Submitted [1] |
| 19 | |
| 20 | [1] https://bugzilla.xfce.org/show_bug.cgi?id=12453 |
| 21 | |
| 22 | Signed-off-by: Andreas MΓΌller <schnitzeltony@googlemail.com> |
| 23 | --- |
| 24 | plugins/clock/clock-time.c | 2 +- |
| 25 | 1 file changed, 1 insertion(+), 1 deletion(-) |
| 26 | |
| 27 | diff --git a/plugins/clock/clock-time.c b/plugins/clock/clock-time.c |
| 28 | index b015b13..4459b85 100644 |
| 29 | --- a/plugins/clock/clock-time.c |
| 30 | +++ b/plugins/clock/clock-time.c |
| 31 | @@ -198,7 +198,7 @@ clock_time_get_time (ClockTime *clock_time) |
| 32 | |
| 33 | panel_return_val_if_fail (XFCE_IS_CLOCK_TIME (clock_time), NULL); |
| 34 | |
| 35 | - if (clock_time->timezone != NULL) |
| 36 | + if (g_strcmp0 (clock_time->timezone_name, DEFAULT_TIMEZONE) != 0) |
| 37 | date_time = g_date_time_new_now (clock_time->timezone); |
| 38 | else |
| 39 | date_time = g_date_time_new_now_local (); |
| 40 | -- |
| 41 | 2.5.0 |
| 42 | |