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

Unified Diff: third_party/WebKit/Source/web/resources/listPicker.js

Issue 1980103002: Include auto vertical scrollbar in intrinsicScrollbarLogicalWidth. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: Restore list box height calculation, fix scrollbar width factor Created 4 years, 7 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
« no previous file with comments | « third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/web/resources/listPicker.js
diff --git a/third_party/WebKit/Source/web/resources/listPicker.js b/third_party/WebKit/Source/web/resources/listPicker.js
index 0e25f1ce4329b65262136c01622f26a96dad4ad2..eef5823cb5f1449dd2f1232fc22ccb3e2a29bc51 100644
--- a/third_party/WebKit/Source/web/resources/listPicker.js
+++ b/third_party/WebKit/Source/web/resources/listPicker.js
@@ -225,6 +225,9 @@ ListPicker.prototype._fixWindowSize = function() {
var elementOffsetWidth = this._selectElement.offsetWidth * zoom;
var desiredWindowHeight = noScrollHeight;
var desiredWindowWidth = elementOffsetWidth;
+ // If we already have a vertical scrollbar, subtract it out, it will get re-added below.
+ if (this._selectElement.scrollHeight > this._selectElement.clientHeight)
+ desiredWindowWidth -= scrollbarWidth;
var expectingScrollbar = false;
if (desiredWindowHeight > maxHeight) {
desiredWindowHeight = maxHeight;
« no previous file with comments | « third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698