Closed Bug 435493 Opened 16 years ago Closed 14 years ago

Minimonth doesn't respect Sunbirds timezone setting, always uses system timezone

Categories

(Calendar :: Calendar Frontend, defect)

x86
Windows XP
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: ssitter, Assigned: Fallen)

Details

Attachments

(3 files)

Attached image screenshot β€”
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.15pre) Gecko/20080522 Calendar/0.9pre

Minimonth doesn't respect Sunbirds timezone setting, always uses system timezone

Steps to Reproduce:
1. Set timezone to Europe/Berlin, restart and create some events
2. Set timezone to Asia/Tokyo, restart and create some events
3. Set timezone to America/Los_Angeles, restart and create some events
4. Set different timezones, restart and check display in main calendar view and minimonth.

Actual Results:
Main calendar view shows the events correctly mapped to the configured timezone. Minimonth shows the events incorrectly on the previous or next day. Same for the today indication. It seems that the minimonth always displays the events mapped into system timezone.

Please see screenshot for better explanation.

Testing was done using system timezone Europe/Berlin (UTC+2) around 23:00. Events were created for Europe/Berlin, Asia/Tokyo and America/Los_Angeles with startime 01:00 and 23:00.
Attached file testcase β€”
Test calendar that contains the events as described above and shown in the screenshot.
Attached patch Fix - v1 β€” β€” Splinter Review
This should take care. It might also solve a bunch of other minimonth issues, I'll check for duplicates in a moment.
Assignee: nobody → philipp
Status: NEW → ASSIGNED
Attachment #433791 - Flags: review?(ssitter)
Attachment #433791 - Flags: review?(ssitter) → review?(Mozilla)
Comment on attachment 433791 [details] [diff] [review]
Fix - v1

Patch works and looks good.

Only one style question:
It sounds a little awkward, but shouldn't it be cal.calGetStartDateProp(aOccurrence) here?
>+        let start = aOccurrence[calGetStartDateProp(aOccurrence)] || aOccurrence.dueDate;
>+        let end = aOccurrence[calGetEndDateProp(aOccurrence)] || start;
When this all is incorporated into calUtils.jsm we should rename these to getStartDateProp and getEndDateProp.
Attachment #433791 - Flags: review?(Mozilla) → review+
In this case I think we should do that renaming when we actually move those
functions, since it indeed sounds a bit awkward.
Pushed to comm-central <http://hg.mozilla.org/comm-central/rev/a1c46c82a4f1>
-> FIXED
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Target Milestone: --- → 1.0b2
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: