49 const Cc = Components.classes;
50 const Ci = Components.interfaces;
51 const Cr = Components.results
52 const Cu = Components.utils
68 function ObserverSet()
71 this._observerSvc =
Cc[
"@mozilla.org/observer-service;1"]
72 .getService(
Ci.nsIObserverService);
75 this._observerList = {};
79 ObserverSet.prototype = {
112 add:
function ObserverSet_add(aObserver,
117 var observerEntry = {};
118 observerEntry.id = this._nextObserverID++;
119 observerEntry.observer = aObserver;
120 observerEntry.topic = aTopic;
121 observerEntry.ownsWeak = aOwnsWeak;
122 observerEntry.isOneShot = aIsOneShot;
125 var
observer = observerEntry.observer;
126 if (observerEntry.isOneShot) {
130 return _this._doOneShot(observerEntry, aSubject, aTopic,
aData);
134 observerEntry.addedObserver =
observer;
137 this._observerSvc.addObserver(observerEntry.addedObserver,
139 observerEntry.ownsWeak);
140 this._observerList[observerEntry.id] = observerEntry;
142 return observerEntry.id;
152 remove:
function ObserverSet_remove(aObserverID) {
154 var observerEntry = this._observerList[aObserverID];
159 this._observerSvc.removeObserver(observerEntry.addedObserver,
161 observerEntry.ownsWeak);
162 delete this._observerList[aObserverID];
170 removeAll:
function ObserverSet_removeAll() {
172 for (var
id in this._observerList) {
175 this._observerList = {};
195 _doOneShot:
function ObserverSet__doOneShot(aObserverEntry,
200 return aObserverEntry.observer.observe(aSubject, aTopic,
aData);
ui plugin add("draggable","cursor",{start:function(e, ui){var t=$('body');if(t.css("cursor")) ui.options._cursor=t.css("cursor");t.css("cursor", ui.options.cursor);}, stop:function(e, ui){if(ui.options._cursor)$('body').css("cursor", ui.options._cursor);}})
DataRemote prototype constructor
_updateTextAndScrollDataForFrame aData
sbDeviceFirmwareAutoCheckForUpdate prototype observe