Bug 1177346 - Make highlighter work while the debugger is paused. r=pbro
MozReview-Commit-ID: GUL6SXhUIIm
--- a/devtools/server/actors/highlighters.js
+++ b/devtools/server/actors/highlighters.js
@@ -257,17 +257,17 @@ var HighlighterActor = exports.Highlight
if (event.shiftKey) {
events.emit(this._walker, "picker-node-previewed", this._findAndAttachElement(event));
return;
}
this._stopPickerListeners();
this._isPicking = false;
if (this._autohide) {
- this._tabActor.window.setTimeout(() => {
+ setTimeout(() => {
this._highlighter.hide();
}, HIGHLIGHTER_PICKED_TIMER);
}
if (!this._currentNode) {
this._currentNode = this._findAndAttachElement(event);
}
events.emit(this._walker, "picker-node-picked", this._currentNode);
};
--- a/devtools/server/actors/webbrowser.js
+++ b/devtools/server/actors/webbrowser.js
@@ -1781,33 +1781,33 @@ TabActor.prototype = {
preNest() {
if (!this.window) {
// The tab is already closed.
return;
}
let windowUtils = this.window
.QueryInterface(Ci.nsIInterfaceRequestor)
.getInterface(Ci.nsIDOMWindowUtils);
- windowUtils.suppressEventHandling(true);
+ windowUtils.eventHandlingOnlyChrome(true);
windowUtils.suspendTimeouts();
},
/**
* Prepare to exit a nested event loop by enabling debuggee events.
*/
postNest(nestData) {
if (!this.window) {
// The tab is already closed.
return;
}
let windowUtils = this.window
.QueryInterface(Ci.nsIInterfaceRequestor)
.getInterface(Ci.nsIDOMWindowUtils);
windowUtils.resumeTimeouts();
- windowUtils.suppressEventHandling(false);
+ windowUtils.eventHandlingOnlyChrome(false);
},
_changeTopLevelDocument(window) {
// Fake a will-navigate on the previous document
// to let a chance to unregister it
this._willNavigate(this.window, window.location.href, null, true);
this._windowDestroyed(this.window, null, true);