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

Unified Diff: third_party/WebKit/Source/core/html/HTMLInputElement.cpp

Issue 2001453002: Set ComputedStyle on Node and use that in buildOwnLayout() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@storage
Patch Set: Created 4 years, 6 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/html/HTMLInputElement.cpp
diff --git a/third_party/WebKit/Source/core/html/HTMLInputElement.cpp b/third_party/WebKit/Source/core/html/HTMLInputElement.cpp
index dc8ac7c79b0d98ee9c0ea2845c48c93daf9c35fd..85bfb8205062021275554bff6ea1b67f6d558e71 100644
--- a/third_party/WebKit/Source/core/html/HTMLInputElement.cpp
+++ b/third_party/WebKit/Source/core/html/HTMLInputElement.cpp
@@ -342,7 +342,7 @@ void HTMLInputElement::updateFocusAppearance(SelectionBehaviorOnFocus selectionB
// TODO(tkent): scrollRectToVisible is a workaround of a bug of
// FrameSelection::revealSelection(). It doesn't scroll correctly in a
// case of RangeSelection. crbug.com/443061.
- if (layoutObject())
+ if (hasLayoutObject())
layoutObject()->scrollRectToVisible(boundingBox());
if (document().frame())
document().frame()->selection().revealSelection();
@@ -893,7 +893,7 @@ void HTMLInputElement::setChecked(bool nowChecked, TextFieldEventBehavior eventB
if (RadioButtonGroupScope* scope = radioButtonGroupScope())
scope->updateCheckedState(this);
- if (layoutObject())
+ if (hasLayoutObject())
LayoutTheme::theme().controlStateChanged(*layoutObject(), CheckedControlState);
setNeedsValidityCheck();
@@ -901,7 +901,7 @@ void HTMLInputElement::setChecked(bool nowChecked, TextFieldEventBehavior eventB
// Ideally we'd do this from the layout tree (matching
// LayoutTextView), but it's not possible to do it at the moment
// because of the way the code is structured.
- if (layoutObject()) {
+ if (hasLayoutObject()) {
if (AXObjectCache* cache = layoutObject()->document().existingAXObjectCache())
cache->checkedStateChanged(this);
}
@@ -929,7 +929,7 @@ void HTMLInputElement::setIndeterminate(bool newValue)
pseudoStateChanged(CSSSelector::PseudoIndeterminate);
- if (layoutObject())
+ if (hasLayoutObject())
LayoutTheme::theme().controlStateChanged(*layoutObject(), CheckedControlState);
}
@@ -1412,7 +1412,7 @@ void HTMLInputElement::setCanReceiveDroppedFiles(bool canReceiveDroppedFiles)
if (!!m_canReceiveDroppedFiles == canReceiveDroppedFiles)
return;
m_canReceiveDroppedFiles = canReceiveDroppedFiles;
- if (layoutObject())
+ if (hasLayoutObject())
layoutObject()->updateFromElement();
}

Powered by Google App Engine
This is Rietveld 408576698