Closed Bug 324665 Opened 19 years ago Closed 19 years ago

New events do not display in day/week view until refresh (Lightning only)

Categories

(Calendar :: Lightning Only, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: stephan.schaefer, Assigned: michael.buettner)

References

Details

Attachments

(1 file, 2 obsolete files)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8) Gecko/20051111 Firefox/1.5
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8) Gecko/20051111 Firefox/1.5

After creating a new event in the week view you have to refresh the view in order to make the event visible.

Reproducible: Always

Steps to Reproduce:
1. Choose a local calendar and enter week view
2. Doubleclick and fill in a title and time in the visible range (eg 15-16)
3. Hit ok

Actual Results:  
The event does not show up, you have to switch views first.

Expected Results:  
The event should appear immediately.
Adding to the blocker list.  This is pretty basic functionality.
OS: Windows XP → All
Hardware: PC → All
Summary: New events do not display until refresh → New events do not display in day/week view until refresh (Lightning only)
taking resposibility for this...
Assignee: nobody → michael.buettner
Attached patch patch for this bug (obsolete) — — Splinter Review
the problem is actually caused at http://lxr.mozilla.org/seamonkey/source/calendar/lightning/content/calendar-management.js#162
this line actually modifies the dates inside the week-view, which causes further calls to findColumnForDate() in calendar-multiweek-view.xml to fail. the solution to the problem is to return a copy of the date the selectedDay-property refers to.
Attachment #210470 - Flags: first-review?(jminta)
Attached patch new proposal (obsolete) — — Splinter Review
changed the patch as discussed on IRC. the getter for week-view::selectedDay does no longer clone the date as i previously proposed, instead the caller that messed around with it now clones the object.
as i noted this morning, the patch for bug #324028 was commited, which makes the problem incidentally disappear. the targetDate gets converted to a 'isDate'-compatible version of the original, but calendar-management.js still messes around with the internal data of the view, so this patch isn't obsolete.
Attachment #210470 - Attachment is obsolete: true
Attachment #210566 - Flags: first-review?(jminta)
Attachment #210470 - Flags: first-review?(jminta)
Comment on attachment 210566 [details] [diff] [review]
new proposal

Can you also do .makeImmutable() in the view's selectedDay getter(s) so that no more of these problems creep in unexpectedly?
Attachment #210566 - Flags: first-review?(jminta) → first-review-
Attached patch new proposal — — Splinter Review
added .makeImmutable() appropriately
Attachment #210566 - Attachment is obsolete: true
Attachment #210863 - Flags: first-review?(jminta)
Comment on attachment 210863 [details] [diff] [review]
new proposal

r=jminta Thanks for your patience on this patch.
Attachment #210863 - Flags: first-review?(jminta) → first-review+
Patch checked in.  Let's keep an eye out to see if that makeImmutable() unearths any other problems.
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: