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

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

Issue 394433002: Add :indeterminate pseudo class support for radio button input (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 3 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/HTMLInputElement.h ('k') | Source/core/html/forms/CheckboxInputType.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLInputElement.cpp
diff --git a/Source/core/html/HTMLInputElement.cpp b/Source/core/html/HTMLInputElement.cpp
index e25afac4f9495da3f6ae846aa86dc95cf05ef5f3..b90e8b45242f22c10ffad1b8a7862215e777f1a7 100644
--- a/Source/core/html/HTMLInputElement.cpp
+++ b/Source/core/html/HTMLInputElement.cpp
@@ -1704,7 +1704,7 @@ String HTMLInputElement::defaultToolTip() const
bool HTMLInputElement::shouldAppearIndeterminate() const
{
- return m_inputType->supportsIndeterminateAppearance() && indeterminate();
+ return m_inputType->shouldAppearIndeterminate();
}
bool HTMLInputElement::isInRequiredRadioButtonGroup()
@@ -1715,8 +1715,10 @@ bool HTMLInputElement::isInRequiredRadioButtonGroup()
return false;
}
-HTMLInputElement* HTMLInputElement::checkedRadioButtonForGroup() const
+HTMLInputElement* HTMLInputElement::checkedRadioButtonForGroup()
{
+ if (checked())
+ return this;
if (RadioButtonGroupScope* scope = radioButtonGroupScope())
return scope->checkedButtonForGroup(name());
return 0;
« no previous file with comments | « Source/core/html/HTMLInputElement.h ('k') | Source/core/html/forms/CheckboxInputType.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698