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

Unified Diff: third_party/WebKit/Source/devtools/front_end/dom_extension/DOMExtension.js

Issue 2747553002: [DevTools] Rework Popover API (Closed)
Patch Set: rebased Created 3 years, 9 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: third_party/WebKit/Source/devtools/front_end/dom_extension/DOMExtension.js
diff --git a/third_party/WebKit/Source/devtools/front_end/dom_extension/DOMExtension.js b/third_party/WebKit/Source/devtools/front_end/dom_extension/DOMExtension.js
index dd12c013026953a83e5d8512b85c04db19ccdcba..f9d202ca5a5707aecd46a3361aceb160e9e89138 100644
--- a/third_party/WebKit/Source/devtools/front_end/dom_extension/DOMExtension.js
+++ b/third_party/WebKit/Source/devtools/front_end/dom_extension/DOMExtension.js
@@ -472,6 +472,15 @@ var AnchorBox = class {
this.width = width || 0;
this.height = height || 0;
}
+
+ /**
+ * @param {number} x
+ * @param {number} y
+ * @return {boolean}
+ */
+ contains(x, y) {
+ return x >= this.x && x <= this.x + this.width && y >= this.y && y <= this.y + this.height;
+ }
};
/**

Powered by Google App Engine
This is Rietveld 408576698