! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
interface to change timezone is not consistent with orage
Status:
CLOSED: FIXED
Component:
clock-plugin

Comments

Description Yves-Alexis Perez editbugs 2008-02-26 07:30:11 CET
Hi,

the button to change the timezone in orage clock plugin is not consistent with the one in Orage itself. More, the version is Orage is nice, it presents you directly a tree with all timezones, organized by continent.

In orageclock, you have to go trough the filesystem, wich can be a pain, and especially because here, the pre-registered path is “/usr/local/etc/zoneinfo” wich doesn't exist and is not consistent with “prefix” where orage was installed (“/usr”).

Cheers,

--
Yves-Alexis
Comment 1 juha editbugs 2008-02-26 10:09:02 CET
yep. Orage uses local libical timezones and orag panel plugin uses os timezones.
I know, not good, but not easy to fix....
Good that this is now reported and visible.


But what is wrong with the pre registered path? 
The code has:
....
if (gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(dialog)
            , "/usr/local/etc/zoneinfo/GMT") == FALSE)
    gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(dialog)
            , "/usr/share/zoneinfo/GMT");
...
So if /usr/local/etc/zoneinfo is valid, it is used and if not 
/usr/share/zoneinfo is used.

Are you getting /usr/local/etc/zoneinfo even though that directory does not exist? 
/usr/share/zoneinfo is correct? isn't it?
Comment 2 Yves-Alexis Perez editbugs 2008-02-26 10:33:24 CET
(In reply to comment #1)
> yep. Orage uses local libical timezones and orag panel plugin uses os
> timezones.
> I know, not good, but not easy to fix....
> Good that this is now reported and visible.

Ha, too bad.
> 
> 
> But what is wrong with the pre registered path? 
> The code has:
> ....
> if (gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(dialog)
>             , "/usr/local/etc/zoneinfo/GMT") == FALSE)
>     gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(dialog)
>             , "/usr/share/zoneinfo/GMT");
> ...
> So if /usr/local/etc/zoneinfo is valid, it is used and if not 
> /usr/share/zoneinfo is used.
> 
> Are you getting /usr/local/etc/zoneinfo even though that directory does not
> exist? 

Yes

> /usr/share/zoneinfo is correct? isn't it?

Yes
Comment 3 juha editbugs 2008-02-26 11:23:21 CET
ok. I can reproduce this with Gtk+ 2.12.0 (Ubuntu 7.10)
but it works correctly   with Gtk+ 2.8.20 (Ubuntu 6.02)

So it looks like Gtk+ BUG to me, but I will search more.
Comment 4 Yves-Alexis Perez editbugs 2008-02-26 13:06:00 CET
(In reply to comment #2)
> (In reply to comment #1)
> > yep. Orage uses local libical timezones and orag panel plugin uses os
> > timezones.
> > I know, not good, but not easy to fix....
> > Good that this is now reported and visible.
> 
> Ha, too bad.
> > 
> > 
> > But what is wrong with the pre registered path? 
> > The code has:
> > ....
> > if (gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(dialog)
> >             , "/usr/local/etc/zoneinfo/GMT") == FALSE)
> >     gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(dialog)
> >             , "/usr/share/zoneinfo/GMT");

gtk_file_chooser_set_filename() seems to be asynchronous, so no useful result is returned before the "selection-changed" signal is sent. Maybe there's some kind of race condition wich shows up only since gtk 2.12?

Maybe testing 

if (!gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(dialog)
            , "/usr/local/etc/zoneinfo/GMT"))
    gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(dialog)
            , "/usr/share/zoneinfo/GMT");

or something like that (so it would match the NULL or something like that)

See 
http://bugzilla.gnome.org/show_bug.cgi?id=340835
http://bugzilla.gnome.org/show_bug.cgi?id=327243

where there are some details. Dont know if it can help.

Cheers,

--
Yves-Alexis
Comment 5 juha editbugs 2008-02-26 14:34:09 CET
Basically gtk_file_chooser_set_filename seems to return always TRUE in the new
versions. To me it looks badly broken. It can only be used to set the files
and not test anymore. (Perhaps those complex loops in those bugs could help, but
documentation does not warn about those and it really always returns now TRUE 
unline in earlier releases.)

Anyway, I fixed this issue by using the most common default first. 

commited in trunk Orage 4.5.12.10 revision 26643

The bigger issue of inconsistency of timezone selection between Orage and the 
panel pluging is more difficult to fix and that is still open.
Comment 6 Yves-Alexis Perez editbugs 2008-02-26 15:18:08 CET
(In reply to comment #5)
> Anyway, I fixed this issue by using the most common default first. 
> 
> commited in trunk Orage 4.5.12.10 revision 26643

thanks !
Comment 7 juha editbugs 2009-09-06 19:26:24 CEST
Finally coded all timezone selections to be the same look and feel.
Also the source is the same. 

Available in git Orage 4.7.4
Comment 8 juha editbugs 2011-01-18 14:06:17 CET
in 4.8.0

Bug #3876

Reported by:
Yves-Alexis Perez
Reported on: 2008-02-26
Last modified on: 2011-01-18

People

CC List:
0 users

Version

Version:
unspecified

Attachments

Additional information