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

Side by Side Diff: Source/core/accessibility/AXNodeObject.cpp

Issue 183183005: Add an accessibility role for the iframe element (re-land). (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 6 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | Source/core/accessibility/AXObject.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 if (isHTMLDivElement(*node())) 214 if (isHTMLDivElement(*node()))
215 return DivRole; 215 return DivRole;
216 if (isHTMLParagraphElement(*node())) 216 if (isHTMLParagraphElement(*node()))
217 return ParagraphRole; 217 return ParagraphRole;
218 if (isHTMLLabelElement(*node())) 218 if (isHTMLLabelElement(*node()))
219 return LabelRole; 219 return LabelRole;
220 if (node()->isElementNode() && toElement(node())->isFocusable()) 220 if (node()->isElementNode() && toElement(node())->isFocusable())
221 return GroupRole; 221 return GroupRole;
222 if (isHTMLAnchorElement(*node()) && isClickable()) 222 if (isHTMLAnchorElement(*node()) && isClickable())
223 return LinkRole; 223 return LinkRole;
224 if (node()->hasTagName(iframeTag))
225 return IframeRole;
224 226
225 return UnknownRole; 227 return UnknownRole;
226 } 228 }
227 229
228 AccessibilityRole AXNodeObject::determineAriaRoleAttribute() const 230 AccessibilityRole AXNodeObject::determineAriaRoleAttribute() const
229 { 231 {
230 const AtomicString& ariaRole = getAttribute(roleAttr); 232 const AtomicString& ariaRole = getAttribute(roleAttr);
231 if (ariaRole.isNull() || ariaRole.isEmpty()) 233 if (ariaRole.isNull() || ariaRole.isEmpty())
232 return UnknownRole; 234 return UnknownRole;
233 235
(...skipping 1433 matching lines...) Expand 10 before | Expand all | Expand 10 after
1667 float range = maxValueForRange() - minValueForRange(); 1669 float range = maxValueForRange() - minValueForRange();
1668 float value = valueForRange(); 1670 float value = valueForRange();
1669 1671
1670 value += range * (percentChange / 100); 1672 value += range * (percentChange / 100);
1671 setValue(String::number(value)); 1673 setValue(String::number(value));
1672 1674
1673 axObjectCache()->postNotification(node(), AXObjectCache::AXValueChanged, tru e); 1675 axObjectCache()->postNotification(node(), AXObjectCache::AXValueChanged, tru e);
1674 } 1676 }
1675 1677
1676 } // namespace WebCore 1678 } // namespace WebCore
OLDNEW
« no previous file with comments | « no previous file | Source/core/accessibility/AXObject.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698