X-Git-Url: http://git.maemo.org/git/?a=blobdiff_plain;f=src%2Fmaemo%2Fmodest-main-window.c;h=ce89897b2369163fd10120b26081a4faa2b4dce6;hb=11d0b1ecfdd84c1711e11ed3384536a3aa0c9edf;hp=25f744e4b187fb9786c9911b104ebf4ee848f1a8;hpb=ab5e47a8570068f507a26a148a0dbecbb51c1bab;p=modest diff --git a/src/maemo/modest-main-window.c b/src/maemo/modest-main-window.c index 25f744e..ce89897 100644 --- a/src/maemo/modest-main-window.c +++ b/src/maemo/modest-main-window.c @@ -64,6 +64,9 @@ #include "maemo/modest-osso-state-saving.h" #include "modest-text-utils.h" #include "modest-signal-mgr.h" +#ifdef MODEST_USE_LIBTIME +#include +#endif #define MODEST_MAIN_WINDOW_ACTION_GROUP_ADDITIONS "ModestMainWindowActionAdditions" @@ -2028,6 +2031,16 @@ create_details_widget (GtkWidget *styled_widget, TnyAccount *account) last_updated = modest_account_mgr_get_last_updated (modest_runtime_get_account_mgr (), tny_account_get_id (account)); +#ifdef MODEST_USE_LIBTIME + /* If we use libtime, we are storing the time in UTC so we have to convert to currently + * selected time */ + time_t now; + struct tm *localtime_tm; + time (&now); + localtime_tm = localtime (&now); + last_updated -= time_get_utc_offset (localtime_tm->tm_zone); +#endif + if (last_updated > 0) last_updated_string = modest_text_utils_get_display_date(last_updated); else