Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1796)

Unified Diff: Source/devtools/front_end/elements/EventListenersWidget.js

Issue 1268353005: [DevTools] Support JQuery event listeners (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Added UI Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/devtools/front_end/elements/EventListenersWidget.js
diff --git a/Source/devtools/front_end/elements/EventListenersWidget.js b/Source/devtools/front_end/elements/EventListenersWidget.js
index d704e0e2f9ab7323ae4f4cfda5d8dc0c70f20eee..d9987ffe83f06c8f75fb19a98f7599e57ebcb941 100644
--- a/Source/devtools/front_end/elements/EventListenersWidget.js
+++ b/Source/devtools/front_end/elements/EventListenersWidget.js
@@ -38,6 +38,10 @@ WebInspector.EventListenersWidget = function()
this._showForAncestorsSetting = WebInspector.settings.createSetting("showEventListenersForAncestors", true);
this._showForAncestorsSetting.addChangeListener(this.update.bind(this));
+
+ this._resolveFrameworkHandlersSetting = WebInspector.settings.createSetting("resolveFrameworkHandlers", true);
+ this._resolveFrameworkHandlersSetting.addChangeListener(this.update.bind(this));
+
this._eventListenersView = new WebInspector.EventListenersView(this.element);
WebInspector.context.addFlavorChangeListener(WebInspector.DOMNode, this.update, this);
}
@@ -53,6 +57,7 @@ WebInspector.EventListenersWidget.createSidebarWrapper = function()
refreshButton.addEventListener("click", widget.update.bind(widget));
result.toolbar().appendToolbarItem(refreshButton);
result.toolbar().appendToolbarItem(new WebInspector.ToolbarCheckbox(WebInspector.UIString("Ancestors"), WebInspector.UIString("Show listeners on the ancestors"), widget._showForAncestorsSetting));
+ result.toolbar().appendToolbarItem(new WebInspector.ToolbarCheckbox(WebInspector.UIString("Resolve handlers"), WebInspector.UIString("Resolve framework's event handlers"), widget._resolveFrameworkHandlersSetting));
yurys 2015/08/12 21:56:03 Framework handlers
return result;
}
@@ -90,7 +95,7 @@ WebInspector.EventListenersWidget.prototype = {
}
promises.push(this._windowObjectInNodeContext(node));
}
- Promise.all(promises).then(this._eventListenersView.addObjects.bind(this._eventListenersView)).then(finishCallback.bind(this, undefined));
+ Promise.all(promises).then(this._eventListenersView.addObjects.bind(this._eventListenersView, this._resolveFrameworkHandlersSetting.get())).then(finishCallback.bind(this, undefined));
},
/**

Powered by Google App Engine
This is Rietveld 408576698