289
edits
No edit summary |
No edit summary |
||
| Line 1: | Line 1: | ||
==Migration to the new views== | |||
So, it looks like the xbl model won out. Unlike my previous patches to bring in the new views, this one cannot be easily implemented in one step. Here's how I'm proposing to go about this: | |||
===Step 1:=== | |||
*Create xbl elements for each of the 4 views we want to implement | |||
*These views will implement the following API | |||
**readonly attribute observerID (not used until Step 2) | |||
**readonly attribute startDay | |||
**readonly attribute endDay | |||
**attribute selectedDay | |||
**attribute controller | |||
**void switchTo(dayToBaseViewOn) | |||
**void switchFrom() | |||
**void moveView(numberOfTimes) | |||
*These views will still be controlled by a shell of gCalendarWindow, mostly to control enabling/disabling commands | |||
===Step 2:=== | |||
Make the views truly pluggable: | |||
*Remove all traces of gCalendarWindow | |||
**make CalendarEventSelection stand on its own | |||
*switching to a view will activate its observer. Commands related to the view should update themselves accordingly (disable/enable) | |||
===xbl model=== | ===xbl model=== | ||
<deck id="view-deck"> | <deck id="view-deck"> | ||
| Line 15: | Line 35: | ||
gCalendarWindow.switchToDayView() becomes switchView('day-view'); | gCalendarWindow.switchToDayView() becomes switchView('day-view'); | ||
edits