OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012, Google Inc. All rights reserved. | 2 * Copyright (C) 2012, Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 781 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
792 HTMLInputElement& input = toHTMLInputElement(*node); | 792 HTMLInputElement& input = toHTMLInputElement(*node); |
793 if (input.isTextField()) | 793 if (input.isTextField()) |
794 return input.isReadOnly(); | 794 return input.isReadOnly(); |
795 } | 795 } |
796 | 796 |
797 return !node->hasEditableStyle(); | 797 return !node->hasEditableStyle(); |
798 } | 798 } |
799 | 799 |
800 bool AXNodeObject::isRequired() const | 800 bool AXNodeObject::isRequired() const |
801 { | 801 { |
802 if (equalIgnoringCase(getAttribute(aria_requiredAttr), "true")) | |
803 return true; | |
804 | |
805 Node* n = this->node(); | 802 Node* n = this->node(); |
806 if (n && (n->isElementNode() && toElement(n)->isFormControlElement())) | 803 if (n && (n->isElementNode() && toElement(n)->isFormControlElement())) |
807 return toHTMLFormControlElement(n)->isRequired(); | 804 return toHTMLFormControlElement(n)->isRequired(); |
808 | 805 |
| 806 if (equalIgnoringCase(getAttribute(aria_requiredAttr), "true")) |
| 807 return true; |
| 808 |
809 return false; | 809 return false; |
810 } | 810 } |
811 | 811 |
812 bool AXNodeObject::canSetFocusAttribute() const | 812 bool AXNodeObject::canSetFocusAttribute() const |
813 { | 813 { |
814 Node* node = this->node(); | 814 Node* node = this->node(); |
815 if (!node) | 815 if (!node) |
816 return false; | 816 return false; |
817 | 817 |
818 if (isWebArea()) | 818 if (isWebArea()) |
(...skipping 1036 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1855 float range = maxValueForRange() - minValueForRange(); | 1855 float range = maxValueForRange() - minValueForRange(); |
1856 float value = valueForRange(); | 1856 float value = valueForRange(); |
1857 | 1857 |
1858 value += range * (percentChange / 100); | 1858 value += range * (percentChange / 100); |
1859 setValue(String::number(value)); | 1859 setValue(String::number(value)); |
1860 | 1860 |
1861 axObjectCache()->postNotification(node(), AXObjectCacheImpl::AXValueChanged,
true); | 1861 axObjectCache()->postNotification(node(), AXObjectCacheImpl::AXValueChanged,
true); |
1862 } | 1862 } |
1863 | 1863 |
1864 } // namespace blink | 1864 } // namespace blink |
OLD | NEW |