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

Side by Side Diff: Source/modules/accessibility/AXObject.cpp

Issue 1052603002: Revert of AX nodes that aren't contenteditable should be readonly. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@listboxes_too
Patch Set: Created 5 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 | « Source/modules/accessibility/AXObject.h ('k') | no next file » | 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) 2008, 2009, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2008, 2009, 2011 Apple 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 332 matching lines...) Expand 10 before | Expand all | Expand 10 after
343 case TabRole: 343 case TabRole:
344 case TextAreaRole: 344 case TextAreaRole:
345 case TextFieldRole: 345 case TextFieldRole:
346 case ToggleButtonRole: 346 case ToggleButtonRole:
347 return true; 347 return true;
348 default: 348 default:
349 return false; 349 return false;
350 } 350 }
351 } 351 }
352 352
353 bool AXObject::isReadOnly() const
354 {
355 if (node())
356 return !node()->hasEditableStyle();
357
358 return true;
359 }
360
361 bool AXObject::accessibilityIsIgnored() const 353 bool AXObject::accessibilityIsIgnored() const
362 { 354 {
363 updateCachedAttributeValuesIfNeeded(); 355 updateCachedAttributeValuesIfNeeded();
364 return m_cachedIsIgnored; 356 return m_cachedIsIgnored;
365 } 357 }
366 358
367 void AXObject::updateCachedAttributeValuesIfNeeded() const 359 void AXObject::updateCachedAttributeValuesIfNeeded() const
368 { 360 {
369 AXObjectCacheImpl* cache = axObjectCache(); 361 AXObjectCacheImpl* cache = axObjectCache();
370 if (!cache) 362 if (!cache)
(...skipping 754 matching lines...) Expand 10 before | Expand all | Expand 10 after
1125 } 1117 }
1126 1118
1127 const AtomicString& AXObject::roleName(AccessibilityRole role) 1119 const AtomicString& AXObject::roleName(AccessibilityRole role)
1128 { 1120 {
1129 static const Vector<AtomicString>* roleNameVector = createRoleNameVector(); 1121 static const Vector<AtomicString>* roleNameVector = createRoleNameVector();
1130 1122
1131 return roleNameVector->at(role); 1123 return roleNameVector->at(role);
1132 } 1124 }
1133 1125
1134 } // namespace blink 1126 } // namespace blink
OLDNEW
« no previous file with comments | « Source/modules/accessibility/AXObject.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698