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 709 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
720 // Note: we can't call node()->willRespondToMouseClickEvents() because t
hat triggers a style recalc and can delete this. | 720 // Note: we can't call node()->willRespondToMouseClickEvents() because t
hat triggers a style recalc and can delete this. |
721 if (node()->hasEventListeners(EventTypeNames::mouseup) || node()->hasEve
ntListeners(EventTypeNames::mousedown) || node()->hasEventListeners(EventTypeNam
es::click) || node()->hasEventListeners(EventTypeNames::DOMActivate)) | 721 if (node()->hasEventListeners(EventTypeNames::mouseup) || node()->hasEve
ntListeners(EventTypeNames::mousedown) || node()->hasEventListeners(EventTypeNam
es::click) || node()->hasEventListeners(EventTypeNames::DOMActivate)) |
722 return true; | 722 return true; |
723 } | 723 } |
724 | 724 |
725 return AXObject::isClickable(); | 725 return AXObject::isClickable(); |
726 } | 726 } |
727 | 727 |
728 bool AXNodeObject::isEnabled() const | 728 bool AXNodeObject::isEnabled() const |
729 { | 729 { |
730 if (equalIgnoringCase(getAttribute(aria_disabledAttr), "true")) | 730 if (isDescendantOfDisabledParent()) |
731 return false; | 731 return false; |
732 | 732 |
733 Node* node = this->node(); | 733 Node* node = this->node(); |
734 if (!node || !node->isElementNode()) | 734 if (!node || !node->isElementNode()) |
735 return true; | 735 return true; |
736 | 736 |
737 return !toElement(node)->isDisabledFormControl(); | 737 return !toElement(node)->isDisabledFormControl(); |
738 } | 738 } |
739 | 739 |
740 AccessibilityExpanded AXNodeObject::isExpanded() const | 740 AccessibilityExpanded AXNodeObject::isExpanded() const |
(...skipping 1251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1992 float range = maxValueForRange() - minValueForRange(); | 1992 float range = maxValueForRange() - minValueForRange(); |
1993 float value = valueForRange(); | 1993 float value = valueForRange(); |
1994 | 1994 |
1995 value += range * (percentChange / 100); | 1995 value += range * (percentChange / 100); |
1996 setValue(String::number(value)); | 1996 setValue(String::number(value)); |
1997 | 1997 |
1998 axObjectCache()->postNotification(node(), AXObjectCacheImpl::AXValueChanged,
true); | 1998 axObjectCache()->postNotification(node(), AXObjectCacheImpl::AXValueChanged,
true); |
1999 } | 1999 } |
2000 | 2000 |
2001 } // namespace blink | 2001 } // namespace blink |
OLD | NEW |