2010-08-13 Sheriff Bot <webkit.review.bot@gmail.com>

        Unreviewed, rolling out r65204.
        http://trac.webkit.org/changeset/65204
        https://bugs.webkit.org/show_bug.cgi?id=43965

        Caused a lot of test crashes in Chromium (Requested by yutak
        on #webkit).

        * platform/mac/accessibility/native-vs-nonnative-checkboxes-expected.txt: Removed.
        * platform/mac/accessibility/native-vs-nonnative-checkboxes.html: Removed.
2010-08-13  Sheriff Bot  <webkit.review.bot@gmail.com>

        Unreviewed, rolling out r65204.
        http://trac.webkit.org/changeset/65204
        https://bugs.webkit.org/show_bug.cgi?id=43965

        Caused a lot of test crashes in Chromium (Requested by yutak
        on #webkit).

        * accessibility/AccessibilityRenderObject.cpp:
        (WebCore::AccessibilityRenderObject::isInputImage):
        (WebCore::AccessibilityRenderObject::isNativeCheckboxOrRadio):
        * dom/InputElement.h:
        * html/HTMLInputElement.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@65317 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 07d9c24f
2010-08-13 Sheriff Bot <webkit.review.bot@gmail.com>
Unreviewed, rolling out r65204.
http://trac.webkit.org/changeset/65204
https://bugs.webkit.org/show_bug.cgi?id=43965
Caused a lot of test crashes in Chromium (Requested by yutak
on #webkit).
* platform/mac/accessibility/native-vs-nonnative-checkboxes-expected.txt: Removed.
* platform/mac/accessibility/native-vs-nonnative-checkboxes.html: Removed.
2010-08-13 Yury Semikhatsky <yurys@chromium.org>
Reviewed by Pavel Feldman.
check1
check2
check2
This tests that input types masquerading as checkboxes will use the aria-checked values for its value.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS accessibilityController.focusedElement.intValue is 1
PASS accessibilityController.focusedElement.intValue is 0
PASS accessibilityController.focusedElement.intValue is 2
PASS successfullyParsed is true
TEST COMPLETE
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<link rel="stylesheet" href="../../../fast/js/resources/js-test-style.css">
<script>
var successfullyParsed = false;
</script>
<script src="../../../fast/js/resources/js-test-pre.js"></script>
</head>
<body id="body">
<input type="image" role="checkbox" aria-checked="true" id="check1">check1<BR>
<input type="image" role="checkbox" aria-checked="mixed" id="check2">check2<BR>
<input type="image" role="checkbox" id="check3">check2<BR>
<p id="description"></p>
<div id="console"></div>
<script>
description("This tests that input types masquerading as checkboxes will use the aria-checked values for its value.");
if (window.accessibilityController) {
// aria-state=true
document.getElementById("check1").focus();
shouldBe("accessibilityController.focusedElement.intValue", "1");
// aria-state=false
document.getElementById("check3").focus();
shouldBe("accessibilityController.focusedElement.intValue", "0");
// aria-state=mixed
document.getElementById("check2").focus();
shouldBe("accessibilityController.focusedElement.intValue", "2");
}
successfullyParsed = true;
</script>
<script src="../../../fast/js/resources/js-test-post.js"></script>
</body>
</html>
2010-08-13 Sheriff Bot <webkit.review.bot@gmail.com>
Unreviewed, rolling out r65204.
http://trac.webkit.org/changeset/65204
https://bugs.webkit.org/show_bug.cgi?id=43965
Caused a lot of test crashes in Chromium (Requested by yutak
on #webkit).
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::isInputImage):
(WebCore::AccessibilityRenderObject::isNativeCheckboxOrRadio):
* dom/InputElement.h:
* html/HTMLInputElement.h:
2010-08-13 Anton Muhin <antonm@chromium.org>
Reviewed by Nate Chapin.
......@@ -508,9 +508,8 @@ bool AccessibilityRenderObject::isFileUploadButton() const
bool AccessibilityRenderObject::isInputImage() const
{
Node* elementNode = node();
if (roleValue() == ButtonRole && elementNode && elementNode->hasTagName(inputTag)) {
HTMLInputElement* input = static_cast<HTMLInputElement*>(elementNode);
if (m_renderer && m_renderer->node() && m_renderer->node()->hasTagName(inputTag)) {
HTMLInputElement* input = static_cast<HTMLInputElement*>(m_renderer->node());
return input->inputType() == HTMLInputElement::IMAGE;
}
......@@ -592,11 +591,8 @@ bool AccessibilityRenderObject::isIndeterminate() const
bool AccessibilityRenderObject::isNativeCheckboxOrRadio() const
{
Node* elementNode = node();
if (elementNode && elementNode->isElementNode()) {
InputElement* input = toInputElement(static_cast<Element*>(elementNode));
if (input)
return input->isCheckbox() || input->isRadioButton();
}
if (elementNode && elementNode->isElementNode())
return toInputElement(static_cast<Element*>(elementNode));
return false;
}
......
......@@ -43,9 +43,6 @@ public:
virtual bool isPasswordField() const = 0;
virtual bool isSearchField() const = 0;
virtual bool isTextField() const = 0;
virtual bool isRadioButton() const = 0;
virtual bool isCheckbox() const = 0;
virtual bool supportsMaxLength() const = 0;
virtual bool hasSpinButton() const { return false; }
#if ENABLE(INPUT_SPEECH)
......
......@@ -101,7 +101,6 @@ public:
virtual bool isSearchField() const { return m_type == SEARCH; }
virtual bool isInputTypeHidden() const { return m_type == HIDDEN; }
virtual bool isPasswordField() const { return m_type == PASSWORD; }
virtual bool isCheckbox() const { return m_type == CHECKBOX; }
bool isTelephoneField() const { return m_type == TELEPHONE; }
bool isNumberField() const { return m_type == NUMBER; }
bool isEmailField() const { return m_type == EMAIL; }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment