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

Unified Diff: content/browser/debugger/manual_tests/event-listeners.html

Issue 11645015: Revert r173891 - "DevTools: rename debugger/ to devtools/, move DevTools files into content/rendere… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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: content/browser/debugger/manual_tests/event-listeners.html
diff --git a/content/browser/debugger/manual_tests/event-listeners.html b/content/browser/debugger/manual_tests/event-listeners.html
new file mode 100644
index 0000000000000000000000000000000000000000..4dff96d5c243701daa1a07a4c713088f7a569627
--- /dev/null
+++ b/content/browser/debugger/manual_tests/event-listeners.html
@@ -0,0 +1,30 @@
+<head>
+ <script>
+ function attachListener() {
+ document.getElementById("target").addEventListener("click", listenerFunction, true);
+ document.getElementById("targetParent").addEventListener("click", listenerFunctionParent, true);
+ }
+ function listenerFunctionParent(event) {
+ event.target.textContent = "event handled";
+ }
+ function listenerFunction(event) {
+ event.target.textContent = "event handled";
+ }
+ </script>
+</head>
+<body onload="attachListener()">
+<div id="targetParent">
+ <div id="target"></div>
+</div>
+<p>To begin test, open DevTools, select the Elements panel. Expand the Event Listeners
+pane in the sidebar.
+<ul>
+ <li>Choose the <b>&lt;div id="targetParent"...></b> element.
+You should see the "click" section in the Event Listeners pane. Expand the section to see
+the "listenerFunctionParent" function (at "div#targetParent") under it.
+ <li>Expand the targetParent node in the tree and choose the <b>&lt;div id="target"...></b>
+element. You should see the "click" section in the Event Listeners pane. Expand the section
+to see two functions, "listenerFunctionParent" (at "div#targetParent") and
+"listenerFunction" (at "div#target") under it.
+</ul>
+</body>

Powered by Google App Engine
This is Rietveld 408576698