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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutMenuList.cpp

Issue 1656743002: Removing more implicit LayoutUnit construction (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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/core/layout/LayoutMenuList.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutMenuList.cpp b/third_party/WebKit/Source/core/layout/LayoutMenuList.cpp
index d91a726c5295375ed732bfe223e7149af275b690..5767913e7c84d7024d34b27caf3b75b3712500d6 100644
--- a/third_party/WebKit/Source/core/layout/LayoutMenuList.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutMenuList.cpp
@@ -179,7 +179,7 @@ void LayoutMenuList::updateOptionsWidth()
// Add in the option's text indent. We can't calculate percentage values for now.
float optionWidth = 0;
if (const ComputedStyle* optionStyle = element->computedStyle())
- optionWidth += minimumValueForLength(optionStyle->textIndent(), 0);
+ optionWidth += minimumValueForLength(optionStyle->textIndent(), LayoutUnit());
if (!text.isEmpty())
optionWidth += computeTextWidth(text);
maxOptionWidth = std::max(maxOptionWidth, optionWidth);
@@ -355,7 +355,7 @@ LayoutUnit LayoutMenuList::clientPaddingRight() const
// drop-down button. But leaving room for the button inside the popup menu itself
// looks strange, so we return a small default padding to avoid having a large empty
// space appear on the side of the popup menu.
- return endOfLinePadding;
+ return LayoutUnit(endOfLinePadding);
}
// If the appearance isn't MenulistPart, then the select is styled (non-native), so

Powered by Google App Engine
This is Rietveld 408576698