mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-14 14:02:47 +00:00
Bug 574702: avoid initializing WindowDraggingUtils multiple times due to binding re-attachment (causes dragging jumpiness issues), r=enndeakin
This commit is contained in:
parent
013e10d651
commit
e358a123e2
@ -161,10 +161,13 @@
|
||||
extends="chrome://global/content/bindings/general.xml#statusbar">
|
||||
<implementation>
|
||||
<constructor>
|
||||
if (!this._draggableStarted) {
|
||||
this._draggableStarted = true;
|
||||
try {
|
||||
Components.utils.import("resource://gre/modules/WindowDraggingUtils.jsm");
|
||||
new WindowDraggingElement(this, window);
|
||||
} catch (e) {}
|
||||
}
|
||||
</constructor>
|
||||
</implementation>
|
||||
</binding>
|
||||
@ -262,10 +265,13 @@
|
||||
<binding id="windowdragbox">
|
||||
<implementation>
|
||||
<constructor>
|
||||
if (!this._draggableStarted) {
|
||||
this._draggableStarted = true;
|
||||
try {
|
||||
Components.utils.import("resource://gre/modules/WindowDraggingUtils.jsm");
|
||||
new WindowDraggingElement(this, window);
|
||||
} catch (e) {}
|
||||
}
|
||||
</constructor>
|
||||
</implementation>
|
||||
</binding>
|
||||
|
@ -441,6 +441,8 @@
|
||||
extends="chrome://global/content/bindings/toolbar.xml#toolbar">
|
||||
<implementation>
|
||||
<constructor><![CDATA[
|
||||
if (!this._draggableStarted) {
|
||||
this._draggableStarted = true;
|
||||
try {
|
||||
Components.utils.import("resource://gre/modules/WindowDraggingUtils.jsm");
|
||||
let draggableThis = new WindowDraggingElement(this, window);
|
||||
@ -449,6 +451,7 @@
|
||||
return !this.parentNode.customizing && !window.fullScreen;
|
||||
}
|
||||
} catch (e) {}
|
||||
}
|
||||
]]></constructor>
|
||||
</implementation>
|
||||
</binding>
|
||||
|
Loading…
x
Reference in New Issue
Block a user