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

Unified Diff: third_party/WebKit/Source/devtools/front_end/ui/Popover.js

Issue 1816933002: Devtools: Cut color picker off at bottom instead of the top (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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/ui/Popover.js
diff --git a/third_party/WebKit/Source/devtools/front_end/ui/Popover.js b/third_party/WebKit/Source/devtools/front_end/ui/Popover.js
index cccb6642a28b6339b83807cb020678f627e0853b..576fcb908a892f9c31013d6a9b77602d3eb4a0dd 100644
--- a/third_party/WebKit/Source/devtools/front_end/ui/Popover.js
+++ b/third_party/WebKit/Source/devtools/front_end/ui/Popover.js
@@ -240,7 +240,7 @@ WebInspector.Popover.prototype = {
}
this.element.className = WebInspector.Popover._classNamePrefix + " " + verticalAlignment + "-" + horizontalAlignment + "-arrow";
- this.element.positionAt(newElementPosition.x, newElementPosition.y - borderWidth, container);
+ this.element.positionAt(newElementPosition.x, Math.max(0, newElementPosition.y - borderWidth), container);
this.element.style.width = newElementPosition.width + borderWidth * 2 + "px";
this.element.style.height = newElementPosition.height + borderWidth * 2 + "px";
},

Powered by Google App Engine
This is Rietveld 408576698