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

Unified Diff: Source/core/html/HTMLOptionElement.cpp

Issue 14859003: Remove the compile time flag for DATALIST Element. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add <datalist> display:none rule in RenderTheme::extraDefaultStyleSheet depending on the runtime fl… Created 7 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
Index: Source/core/html/HTMLOptionElement.cpp
diff --git a/Source/core/html/HTMLOptionElement.cpp b/Source/core/html/HTMLOptionElement.cpp
index e689cd38b8651c4d3f70a81628c51fcaf5373997..6dab7339abbf7b5ac5ec516f8d9433a9c60bf4f0 100644
--- a/Source/core/html/HTMLOptionElement.cpp
+++ b/Source/core/html/HTMLOptionElement.cpp
@@ -194,12 +194,10 @@ int HTMLOptionElement::index() const
void HTMLOptionElement::parseAttribute(const QualifiedName& name, const AtomicString& value)
{
-#if ENABLE(DATALIST_ELEMENT)
if (name == valueAttr) {
if (HTMLDataListElement* dataList = ownerDataListElement())
dataList->optionElementChildrenChanged();
} else
tkent 2013/05/20 21:32:11 should be "} else if (..."
-#endif
if (name == disabledAttr) {
bool oldDisabled = m_disabled;
m_disabled = !value.isNull();
@@ -275,17 +273,14 @@ void HTMLOptionElement::setSelectedState(bool selected)
void HTMLOptionElement::childrenChanged(bool changedByParser, Node* beforeChange, Node* afterChange, int childCountDelta)
{
-#if ENABLE(DATALIST_ELEMENT)
if (HTMLDataListElement* dataList = ownerDataListElement())
dataList->optionElementChildrenChanged();
else
tkent 2013/05/20 21:32:11 should be "else if (..."
-#endif
if (HTMLSelectElement* select = ownerSelectElement())
select->optionElementChildrenChanged();
HTMLElement::childrenChanged(changedByParser, beforeChange, afterChange, childCountDelta);
}
-#if ENABLE(DATALIST_ELEMENT)
HTMLDataListElement* HTMLOptionElement::ownerDataListElement() const
{
for (ContainerNode* parent = parentNode(); parent ; parent = parent->parentNode()) {
@@ -294,7 +289,6 @@ HTMLDataListElement* HTMLOptionElement::ownerDataListElement() const
}
return 0;
}
-#endif
HTMLSelectElement* HTMLOptionElement::ownerSelectElement() const
{

Powered by Google App Engine
This is Rietveld 408576698