[Webkit-unassigned] [Bug 74914] New: :invalid style is not applied when a checked radio button is removed from its radio group
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Dec 19 22:05:28 PST 2011
https://bugs.webkit.org/show_bug.cgi?id=74914
Summary: :invalid style is not applied when a checked radio
button is removed from its radio group
Product: WebKit
Version: 528+ (Nightly build)
Platform: Unspecified
OS/Version: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: Forms
AssignedTo: webkit-unassigned at lists.webkit.org
ReportedBy: tkent at chromium.org
Repro:
<style>
:valid {
border: solid 2px lime;
}
:invalid {
border: solid 2px red;
}
input[type="radio"] {
-webkit-appearance: none;
width: 16px;
height: 16px;
}
input[type="radio"]:checked {
background-color: blue;
}
</style>
<body>
<form id=f>
<input type=radio name=n1 value=a id=a required>
<input type=radio name=n1 value=b id=b checked>
</form>
<script>
function $(id) { return document.getElementById(id); }
$('b').parentNode.removeChild($('b'));
</script>
</body>
This HTML causes an assertion failure with a debug build:
ASSERTION FAILED: m_isValid == validity()->valid()
/Volumes/d2/WebKit/Source/WebCore/html/HTMLFormControlElement.cpp(433) : virtual bool WebCore::HTMLFormControlElement::isValidFormControlElement()
1 0x102fab0d8 WebCore::HTMLFormControlElement::isValidFormControlElement()
2 0x102b32304 WebCore::SelectorChecker::checkOneSelector(WebCore::CSSSelector*, WebCore::Element*, WebCore::PseudoId&, bool, WebCore::SelectorChecker::VisitedMatchType, WebCore::RenderStyle*, WebCore::RenderStyle*) const
3 0x102b2fcfb WebCore::SelectorChecker::checkSelector(WebCore::CSSSelector*, WebCore::Element*, WebCore::PseudoId&, bool, WebCore::SelectorChecker::VisitedMatchType, WebCore::RenderStyle*, WebCore::RenderStyle*) const
4 0x102c16ff0 WebCore::CSSStyleSelector::checkSelector(WebCore::RuleData const&)
5 0x102bf5a82 WebCore::CSSStyleSelector::matchRulesForList(WTF::Vector<WebCore::RuleData, 0ul> const*, int&, int&, bool)
6 0x102bf5fca WebCore::CSSStyleSelector::matchRules(WebCore::RuleSet*, int&, int&, bool)
7 0x102bf6f55 WebCore::CSSStyleSelector::matchAllRules(WebCore::CSSStyleSelector::MatchResult&)
8 0x102bf8809 WebCore::CSSStyleSelector::styleForElement(WebCore::Element*, WebCore::RenderStyle*, bool, bool, WebCore::RenderRegion*)
9 0x102e3afb9 WebCore::Element::styleForRenderer()
10 0x102e3b44d WebCore::Element::recalcStyle(WebCore::Node::StyleChange)
11 ...
We need to call HTMLInputElement::updateCheckedRadioButtons() when a checked radio button is removed from the group.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list