Bug 329581 Most observers are not removed on shutdown, r1=lilmatt, r2=dmose

git-svn-id: svn://10.0.0.236/trunk@208201 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
jminta%gmail.com
2006-08-23 18:10:11 +00:00
parent 2108c032de
commit ea3b5f8717
5 changed files with 19 additions and 0 deletions

View File

@@ -697,6 +697,11 @@
for (var i = 0; i < 7; i++) {
var hdr = createXULElement("calendar-month-view-column-header");
hdr.setAttribute("flex", "1");
headerbox.appendChild(hdr);
hdr.index = i;
}
]]></constructor>
<destructor><![CDATA[
if (this.mCalendar)
this.mCalendar.removeObserver(this.mObserver);

View File

@@ -1573,6 +1573,11 @@
this.reorient();
]]></constructor>
<destructor><![CDATA[
if (this.mCalendar)
this.mCalendar.removeObserver(this.mObserver);
]]></destructor>
<method name="onResize">
<parameter name="aRealSelf"/>
<body><![CDATA[

View File

@@ -46,6 +46,10 @@
<binding id="calendar-todo-list" extends="chrome://global/content/bindings/richlistbox.xml#richlistbox"
implements="calIObserver, calICompositeObserver, calIOperationListener">
<implementation>
<destructor><![CDATA[
if (this.mCalendar)
this.mCalendar.removeObserver(this.mOperationListener);
]]></destructor>
<field name="mCalendar">null</field>
<field name="mOperationListener"><![CDATA[

View File

@@ -295,6 +295,10 @@ function ltnFinish() {
var pb2 = prefService.getBranch("");
pb2 = pb2.QueryInterface(Components.interfaces.nsIPrefBranch2);
pb2.removeObserver("calendar.", ltnPrefObserver);
getCompositeCalendar().removeObserver(agendaTreeView.calendarObserver);
getCompositeCalendar().removeObserver(ltnCompositeCalendarObserver);
getCalendarManager().removeObserver(ltnCalendarManagerObserver);
return;
}

View File

@@ -307,6 +307,7 @@ function finishCalendarManager() {
var calendarList = document.getElementById("list-calendars-listbox");
calendarList.removeEventListener("select", onCalendarListSelect, true);
getCalendarManager().removeObserver(calCalendarManagerObserver);
}
function getDefaultCalendar()