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

Unified Diff: Source/core/html/shadow/DateTimeEditElement.cpp

Issue 428533006: Use ContainerNode::hasChildren() instead of firstChild() in conditionals (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: build fix Created 6 years, 5 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 | « Source/core/html/HTMLTextFormControlElement.cpp ('k') | Source/core/inspector/DOMPatchSupport.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/shadow/DateTimeEditElement.cpp
diff --git a/Source/core/html/shadow/DateTimeEditElement.cpp b/Source/core/html/shadow/DateTimeEditElement.cpp
index 1e77dd76dc890f9627f7a77722feb72c93504253..11bfb528260be3187bcd7ef01486cd0c8edbaabb 100644
--- a/Source/core/html/shadow/DateTimeEditElement.cpp
+++ b/Source/core/html/shadow/DateTimeEditElement.cpp
@@ -662,7 +662,7 @@ bool DateTimeEditElement::isReadOnly() const
void DateTimeEditElement::layout(const LayoutParameters& layoutParameters, const DateComponents& dateValue)
{
DEFINE_STATIC_LOCAL(AtomicString, fieldsWrapperPseudoId, ("-webkit-datetime-edit-fields-wrapper", AtomicString::ConstructFromLiteral));
- if (!firstChild()) {
+ if (!hasChildren()) {
RefPtrWillBeRawPtr<HTMLDivElement> element = HTMLDivElement::create(document());
element->setShadowPseudoId(fieldsWrapperPseudoId);
appendChild(element.get());
« no previous file with comments | « Source/core/html/HTMLTextFormControlElement.cpp ('k') | Source/core/inspector/DOMPatchSupport.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698