From a71364b4a1e764bcbc31826bb632c1fa8e06eafb Mon Sep 17 00:00:00 2001 From: Federico Mena Quintero Date: Tue, 17 Jul 2001 20:07:27 +0000 Subject: Really fixes #4380. The previous fix was necessary but not sufficient; it 2001-07-17 Federico Mena Quintero Really fixes #4380. The previous fix was necessary but not sufficient; it worked for me because my system timezone happens to match the Evolution timezone --- if they don't match, the bug would persist. * cal-util/timeutil.c (time_to_gdate_with_zone): New function. We cannot use g_date_set_time() anymore because it does not take timezones into account. * gui/gnome-cal.c (get_days_shown): Use the function above. * gui/e-day-view.c (e_day_view_find_work_week_start): Likewise. * gui/e-week-view.c (e_week_view_set_selected_time_range): Likewise. 2001-07-17 Jon Trowbridge svn path=/trunk/; revision=11167 --- calendar/ChangeLog | 18 ++++++++++++++++++ calendar/cal-util/timeutil.c | 24 ++++++++++++++++++++++++ calendar/cal-util/timeutil.h | 1 + calendar/gui/e-day-view.c | 3 +++ calendar/gui/e-week-view.c | 7 ++++++- calendar/gui/gnome-cal.c | 10 ++++++---- 6 files changed, 58 insertions(+), 5 deletions(-) diff --git a/calendar/ChangeLog b/calendar/ChangeLog index d3656bcbc8..bab0f9bd19 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,3 +1,20 @@ +2001-07-17 Federico Mena Quintero + + Really fixes #4380. The previous fix was necessary but not + sufficient; it worked for me because my system timezone happens to + match the Evolution timezone --- if they don't match, the bug + would persist. + + * cal-util/timeutil.c (time_to_gdate_with_zone): New function. We + cannot use g_date_set_time() anymore because it does not take + timezones into account. + + * gui/gnome-cal.c (get_days_shown): Use the function above. + + * gui/e-day-view.c (e_day_view_find_work_week_start): Likewise. + + * gui/e-week-view.c (e_week_view_set_selected_time_range): Likewise. + 2001-07-17 Jon Trowbridge * gui/dialogs/meeting-page.c (invite_entry_changed): Print @@ -30,6 +47,7 @@ * gui/dialogs/comp-editor-util.c (comp_editor_dates): * gui/print.c (print_date_label): only free icaltimetype if not NULL. +>>>>>>> 1.974 2001-07-12 Taylor Hayward * gui/goto-dialog.glade: diff --git a/calendar/cal-util/timeutil.c b/calendar/cal-util/timeutil.c index 3a9308c1e1..f66d851399 100644 --- a/calendar/cal-util/timeutil.c +++ b/calendar/cal-util/timeutil.c @@ -393,6 +393,30 @@ time_day_end_with_zone (time_t time, icaltimezone *zone) return icaltime_as_timet_with_zone (tt, zone); } +/** + * time_to_gdate_with_zone: + * @date: Destination #GDate value. + * @time: A time value. + * @zone: Desired timezone for destination @date, or NULL if the UTC timezone + * is desired. + * + * Converts a time_t value to a #GDate structure using the specified timezone. + * This is analogous to g_date_set_time() but takes the timezone into account. + **/ +void +time_to_gdate_with_zone (GDate *date, time_t time, icaltimezone *zone) +{ + struct icaltimetype tt; + + g_return_if_fail (date != NULL); + g_return_if_fail (time != -1); + + tt = icaltime_from_timet_with_zone (time, FALSE, + zone ? zone : icaltimezone_get_utc_timezone ()); + + g_date_set_dmy (date, tt.day, tt.month, tt.year); +} + /************************************************************************** * General time functions. diff --git a/calendar/cal-util/timeutil.h b/calendar/cal-util/timeutil.h index 3679173572..0e2795b287 100644 --- a/calendar/cal-util/timeutil.h +++ b/calendar/cal-util/timeutil.h @@ -116,5 +116,6 @@ time_t time_day_begin_with_zone (time_t time, icaltimezone *zone); timezone. (The end of the day is the start of the next day.) */ time_t time_day_end_with_zone (time_t time, icaltimezone *zone); +void time_to_gdate_with_zone (GDate *date, time_t time, icaltimezone *zone); #endif diff --git a/calendar/gui/e-day-view.c b/calendar/gui/e-day-view.c index 538fede50e..bb5f4d7559 100644 --- a/calendar/gui/e-day-view.c +++ b/calendar/gui/e-day-view.c @@ -2154,8 +2154,11 @@ e_day_view_find_work_week_start (EDayView *day_view, gint weekday, day, i, offset; struct icaltimetype tt = icaltime_null_time (); +#if 0 g_date_clear (&date, 1); g_date_set_time (&date, start_time); +#endif + time_to_gdate_with_zone (&date, start_time, day_view->zone); /* The start of the work-week is the first working day after the week start day. */ diff --git a/calendar/gui/e-week-view.c b/calendar/gui/e-week-view.c index 2cf036289f..32af97d1fa 100644 --- a/calendar/gui/e-week-view.c +++ b/calendar/gui/e-week-view.c @@ -1205,9 +1205,11 @@ e_week_view_set_selected_time_range (EWeekView *week_view, gboolean update_adjustment_value = FALSE; g_return_if_fail (E_IS_WEEK_VIEW (week_view)); - +#if 0 g_date_clear (&date, 1); g_date_set_time (&date, start_time); +#endif + time_to_gdate_with_zone (&date, start_time, week_view->zone); if (week_view->multi_week_view) { /* Find the number of days since the start of the month. */ @@ -1271,8 +1273,11 @@ e_week_view_set_selected_time_range (EWeekView *week_view, week_view->zone)) week_view->selection_end_day = week_view->selection_start_day; else { +#if 0 g_date_clear (&end_date, 1); g_date_set_time (&end_date, end_time - 60); +#endif + time_to_gdate_with_zone (&end_date, end_time - 60, week_view->zone); week_view->selection_end_day = g_date_julian (&end_date) - g_date_julian (&base_date); } diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c index cf8d12bc14..7068fbe1fe 100644 --- a/calendar/gui/gnome-cal.c +++ b/calendar/gui/gnome-cal.c @@ -1692,14 +1692,16 @@ get_days_shown (GnomeCalendar *gcal, GDate *start_date, gint *days_shown) switch (priv->current_view_type) { case GNOME_CAL_DAY_VIEW: - g_date_clear (start_date, 1); - g_date_set_time (start_date, E_DAY_VIEW (priv->day_view)->lower); + time_to_gdate_with_zone (start_date, + E_DAY_VIEW (priv->day_view)->lower, + priv->zone); *days_shown = e_day_view_get_days_shown (E_DAY_VIEW (priv->day_view)); break; case GNOME_CAL_WORK_WEEK_VIEW: - g_date_clear (start_date, 1); - g_date_set_time (start_date, E_DAY_VIEW (priv->work_week_view)->lower); + time_to_gdate_with_zone (start_date, + E_DAY_VIEW (priv->work_week_view)->lower, + priv->zone); *days_shown = e_day_view_get_days_shown (E_DAY_VIEW (priv->work_week_view)); break; -- cgit /npm_and_yarn/devel/electron4/files/eslint-utils-1.4.3'>aboutsummaryrefslogtreecommitdiffstats
path: root/devel
Commit message (Expand)AuthorAgeFilesLines
* New port: devel/rubygem-relinemeta2019-12-134-0/+29
* devel/kf5-threadweaver: fix comment and pkg-descrtcberner2019-12-132-4/+8
* KDE's December 2019 Apps Updatetcberner2019-12-1316-90/+36
* devel/libsigrokdecode: Update to version 0.5.3bsam2019-12-133-5/+38
* devel/cdecl: update to 6.6.2.ler2019-12-122-4/+4
* Update sysutils/libcdio to 2.1.0jhale2019-12-121-1/+1
* devel/avr-gcc: fix build on powerpc64 elfv2pkubaj2019-12-121-0/+11
* devel/intel-graphics-compiler: update to 1.0.3032jbeich2019-12-122-4/+4
* devel/efl: fix build on powerpc64 elfv2pkubaj2019-12-121-0/+12
* Update to 1.0.9sunpoet2019-12-122-4/+4
* Update to 1.8.1sunpoet2019-12-122-4/+4
* Update to 1.0.3sunpoet2019-12-122-4/+4
* Update to 8.3.0sunpoet2019-12-122-4/+4
* Update to 2.11.396sunpoet2019-12-122-4/+4
* Update to 1.64.0sunpoet2019-12-122-4/+4
* Update to 1.58.0sunpoet2019-12-122-4/+4
* Update to 2.11.396sunpoet2019-12-122-4/+4
* Update to 3.62.0sunpoet2019-12-122-4/+7
* Update to 1.73.0sunpoet2019-12-122-4/+4
* Update to 1.16.0sunpoet2019-12-122-4/+4
* Update to 1.34.0sunpoet2019-12-122-4/+4
* Update to 1.27.0sunpoet2019-12-122-4/+4
* Update to 1.16.0sunpoet2019-12-122-4/+4
* Update to 1.119.0sunpoet2019-12-122-4/+4
* Update to 1.41.0sunpoet2019-12-122-4/+4
* Update to 2.11.396sunpoet2019-12-122-4/+4
* Update to 3.81.0sunpoet2019-12-122-4/+4
* Update to 1.45.0sunpoet2019-12-122-4/+4
* Update to 1.35.0sunpoet2019-12-122-4/+4
* Update to 1.243.0sunpoet2019-12-122-4/+4
* Update to 4.2.0sunpoet2019-12-122-4/+4
* Update to 8.0.2sunpoet2019-12-122-4/+4
* Update to 1.5.1sunpoet2019-12-122-4/+4
* Update to 1.2.4sunpoet2019-12-122-4/+4
* Update to 0.15.2sunpoet2019-12-122-4/+4
* Update to 0.7.2sunpoet2019-12-124-33/+4
* Update to 1.008000sunpoet2019-12-123-6/+22
* Update to 0.524sunpoet2019-12-122-6/+6
* Update to 0.108sunpoet2019-12-122-5/+5
* Add NO_ARCHsunpoet2019-12-122-3/+5
* Fix and sort *_DEPENDSsunpoet2019-12-121-4/+3
* Update to 0.048sunpoet2019-12-122-4/+4
* Update to 1.02sunpoet2019-12-122-4/+4
* Add NO_ARCHsunpoet2019-12-121-4/+5
* Update to 4.005sunpoet2019-12-122-4/+4
* Add rubygem-aws-sdk-wafv2 1.0.0sunpoet2019-12-124-0/+30
* Add rubygem-aws-sdk-iotsecuretunneling 1.0.0sunpoet2019-12-124-0/+30
* Add rubygem-aws-sdk-appconfig 1.0.0sunpoet2019-12-124-0/+30
* Add p5-AWS-Signature4 1.02sunpoet2019-12-125-0/+36
* - Update WWWamdmi32019-12-121-1/+1
* Update to fresh qemu-cheri and llvm-cheri snapshots.brooks2019-12-124-25/+65
* - Update to 1.8.5tota2019-12-122-9/+7
* devel/boost-*: update to 1.72.0jbeich2019-12-1264-965/+2048
* - Update to 1.12.8tota2019-12-122-4/+4
* - Update to 2.0.0tota2019-12-122-6/+7
* devel/xeus: don't optimize for the host CPUpkubaj2019-12-111-1/+2
* - Update to 0.167.1amdmi32019-12-112-4/+4
* - Update to 5.0.1amdmi32019-12-112-4/+4
* devel/etc, devel/synfig, graphics/synfigstudio: Update to 1.2.2woodsb022019-12-119-34/+57
* devel/pecl-xdebug: Update to 2.9.0pizzamig2019-12-112-4/+4
* - Fix licenseamdmi32019-12-112-2/+5
* devel/py-oci: Update to 2.7.1meta2019-12-112-4/+4
* devel/libgit2 security upgrade to 0.28.4.mfechner2019-12-114-8/+8
* Updated to g20191130ultima2019-12-113-341/+214
* devel/git-cinnabar: rebuild after r519781jbeich2019-12-111-1/+1
* devel/git: Update to 2.24.1garga2019-12-113-8/+19
* - Add a port of a stand-alone binary AndroidManifest.xml decoderdanfe2019-12-115-0/+75
* Fix build on powerpc64 ELFv2sunpoet2019-12-112-0/+21
* Update to 5.2.4sunpoet2019-12-112-5/+4
* Update to 5.2.4sunpoet2019-12-112-4/+4
* Update to 5.2.4sunpoet2019-12-112-4/+4
* Update to 0.9.2sunpoet2019-12-112-4/+4
* Update to 3.11.1sunpoet2019-12-112-4/+4
* Update to 0.36.0sunpoet2019-12-112-4/+4
* Update to 2.8.1sunpoet2019-12-112-4/+4
* Update to 0.70.0sunpoet2019-12-112-4/+4
* Update to 0.30.0sunpoet2019-12-112-4/+4
* Update to 2.11.395sunpoet2019-12-112-4/+4
* Update to 1.63.0sunpoet2019-12-112-4/+4
* Update to 1.48.0sunpoet2019-12-112-4/+4
* Update to 1.57.0sunpoet2019-12-112-4/+4
* Update to 2.11.395sunpoet2019-12-112-4/+4
* Update to 3.61.0sunpoet2019-12-112-4/+5
* Update to 1.33.0sunpoet2019-12-112-4/+4
* Update to 1.72.0sunpoet2019-12-112-4/+4
* Update to 1.15.0sunpoet2019-12-112-4/+4
* Update to 1.8.0sunpoet2019-12-112-4/+4
* Update to 1.23.0sunpoet2019-12-112-4/+4
* Update to 1.33.0sunpoet2019-12-112-4/+4
* Update to 1.41.0sunpoet2019-12-112-4/+4
* Update to 1.39.0sunpoet2019-12-112-4/+4
* Update to 1.54.0sunpoet2019-12-112-4/+4
* Update to 1.118.0sunpoet2019-12-112-4/+4
* Update to 1.40.0sunpoet2019-12-112-4/+4
* Update to 1.22.0sunpoet2019-12-112-4/+4
* Update to 1.34.0sunpoet2019-12-112-4/+4
* Update to 2.11.395sunpoet2019-12-112-4/+4
* Update to 3.80.0sunpoet2019-12-112-4/+4
* Update to 1.40.0sunpoet2019-12-112-4/+4
* Update to 1.31.0sunpoet2019-12-112-4/+4
* Update to 1.44.0sunpoet2019-12-112-4/+4
* Update to 1.34.0sunpoet2019-12-112-4/+4
* Update to 1.242.0sunpoet2019-12-112-4/+4
* Update to 1.24.0sunpoet2019-12-112-4/+4
* Update to 1.31.0sunpoet2019-12-112-4/+4
* Update to 8.0.1sunpoet2019-12-112-4/+4
* Update to 2.0.1sunpoet2019-12-112-4/+4
* Update to 2.7.1sunpoet2019-12-112-4/+4
* Add PORTSCOUTsunpoet2019-12-111-0/+3
* Update to 1.10.3sunpoet2019-12-112-4/+4
* Update to 3.11.1sunpoet2019-12-112-4/+4
* Update to 1.302170sunpoet2019-12-112-4/+4
* Update to 0.119sunpoet2019-12-112-6/+6
* Update to 0.107sunpoet2019-12-112-5/+5
* Update to 1.707sunpoet2019-12-112-4/+4
* Update to 1.864sunpoet2019-12-112-4/+4
* Update to 1.864sunpoet2019-12-112-4/+4
* Update to 1.80sunpoet2019-12-112-4/+4
* Add rubygem-aws-sdk-connectparticipant 1.0.0sunpoet2019-12-114-0/+31
* Update to 20191209antoine2019-12-102-4/+4
* Update to alpha-20191104antoine2019-12-103-19/+9
* msgpack: Update to 3.2.1adamw2019-12-102-5/+4
* - Update to 5.0.0amdmi32019-12-102-5/+5
* - Update to 2.208lwhsu2019-12-102-4/+4
* Deprecate ports broken for too longantoine2019-12-1010-0/+22
* Update security/cryptopp to 8.2.0jhale2019-12-101-0/+1
* - Move graphics/osg to graphics/osg34 in preparation for update to 3.6amdmi32019-12-101-1/+2
* Update print/ghostscript9-agpl-* to 9.50.tijl2019-12-102-1/+16
* devel/gocheese: create portswills2019-12-105-0/+53
* New port: devel/termcolor: Header-only C++ library for printing colored messa...yuri2019-12-104-0/+37
* - Update to 0.167.0amdmi32019-12-092-4/+4
* devel/creduce: unbreak on powerpc64pkubaj2019-12-091-1/+4
* devel/git-lfs: update 2.9.0_2 to 2.9.1egypcio2019-12-092-5/+4
* devel/ruby-build: Update to 20191205meta2019-12-092-4/+4
* devel/crc32c: Update to 1.1.1meta2019-12-092-5/+4
* devel/py-validators: Update to 0.14.1dbaio2019-12-092-4/+4
* devel/rust-cbindgen: update to 0.11.1jbeich2019-12-092-4/+4
* Update to 0.750sunpoet2019-12-092-6/+5
* Relax USES=pythonsunpoet2019-12-091-2/+3
* Use = instead of ?= for RUN_DEPENDSsunpoet2019-12-091-3/+4
* Add NO_ARCHsunpoet2019-12-091-0/+2
* Add NO_ARCHsunpoet2019-12-091-0/+2
* Update to 2.2.2sunpoet2019-12-092-4/+4
* Update to 2.9.10sunpoet2019-12-092-4/+4
* Fix build after r518196sunpoet2019-12-091-3/+2
* Fix build after r518196sunpoet2019-12-091-3/+2
* Update to 0.7.0sunpoet2019-12-092-4/+4
* Update to 0.20.0sunpoet2019-12-092-5/+5
* Update to 0.1.8sunpoet2019-12-092-4/+4
* Update to 3.10.0sunpoet2019-12-092-4/+4
* Update to 0.5.1sunpoet2019-12-092-4/+4
* Update to 3.2.1sunpoet2019-12-092-4/+4
* Update to 1.2.5sunpoet2019-12-092-5/+4
* Update to 3.11.0sunpoet2019-12-092-4/+4
* Update to 0.35.0sunpoet2019-12-092-4/+4
* Update to 1.11.3sunpoet2019-12-092-4/+4
* Update to 2.8.0sunpoet2019-12-092-4/+4
* Update to 0.69.0sunpoet2019-12-092-4/+4
* Update to 0.29.0sunpoet2019-12-092-4/+4
* Update to 1.6.0sunpoet2019-12-092-4/+4
* Update to 1.0.24sunpoet2019-12-092-4/+4
* Update to 2.11.394sunpoet2019-12-092-4/+4
* Update to 1.32.0sunpoet2019-12-092-4/+4
* Update to 1.33.0sunpoet2019-12-092-4/+4
* Update to 1.12.0sunpoet2019-12-092-4/+4
* Update to 1.34.0sunpoet2019-12-09