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

Side by Side Diff: Source/modules/accessibility/AXNodeObject.h

Issue 1072273006: Oilpan: Prepare moving AXObject to heap (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 6 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
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 28 matching lines...) Expand all
39 class Element; 39 class Element;
40 class HTMLLabelElement; 40 class HTMLLabelElement;
41 class LayoutRect; 41 class LayoutRect;
42 class Node; 42 class Node;
43 43
44 class MODULES_EXPORT AXNodeObject : public AXObject { 44 class MODULES_EXPORT AXNodeObject : public AXObject {
45 protected: 45 protected:
46 AXNodeObject(Node*, AXObjectCacheImpl&); 46 AXNodeObject(Node*, AXObjectCacheImpl&);
47 47
48 public: 48 public:
49 static PassRefPtr<AXNodeObject> create(Node*, AXObjectCacheImpl&); 49 static PassRefPtrWillBeRawPtr<AXNodeObject> create(Node*, AXObjectCacheImpl& );
50 virtual ~AXNodeObject(); 50 virtual ~AXNodeObject();
51 DECLARE_VIRTUAL_TRACE();
51 52
52 protected: 53 protected:
53 // Protected data. 54 // Protected data.
54 AccessibilityRole m_ariaRole; 55 AccessibilityRole m_ariaRole;
55 bool m_childrenDirty; 56 bool m_childrenDirty;
56 #if ENABLE(ASSERT) 57 #if ENABLE(ASSERT)
57 bool m_initialized; 58 bool m_initialized;
58 #endif 59 #endif
59 60
60 virtual bool computeAccessibilityIsIgnored(IgnoredReasons* = nullptr) const override; 61 virtual bool computeAccessibilityIsIgnored(IgnoredReasons* = nullptr) const override;
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 virtual AccessibilityRole ariaRoleAttribute() const override final; 161 virtual AccessibilityRole ariaRoleAttribute() const override final;
161 162
162 // Accessibility Text. 163 // Accessibility Text.
163 virtual String deprecatedTextUnderElement(TextUnderElementMode) const overri de; 164 virtual String deprecatedTextUnderElement(TextUnderElementMode) const overri de;
164 virtual String deprecatedAccessibilityDescription() const override; 165 virtual String deprecatedAccessibilityDescription() const override;
165 virtual String deprecatedTitle(TextUnderElementMode) const override; 166 virtual String deprecatedTitle(TextUnderElementMode) const override;
166 virtual String deprecatedHelpText() const override; 167 virtual String deprecatedHelpText() const override;
167 virtual String computedName() const override; 168 virtual String computedName() const override;
168 169
169 // New AX name calculation. 170 // New AX name calculation.
170 virtual String textAlternative(bool recursive, bool inAriaLabelledByTraversa l, HashSet<AXObject*>& visited, AXNameFrom*, Vector<AXObject*>* nameObjects) ove rride; 171 virtual String textAlternative(bool recursive, bool inAriaLabelledByTraversa l, WillBeHeapHashSet<RawPtrWillBeMember<AXObject>>& visited, AXNameFrom*, WillBe HeapVector<RawPtrWillBeMember<AXObject>>* nameObjects) override;
171 172
172 // Location and click point in frame-relative coordinates. 173 // Location and click point in frame-relative coordinates.
173 virtual LayoutRect elementRect() const override; 174 virtual LayoutRect elementRect() const override;
174 175
175 // High-level accessibility tree access. 176 // High-level accessibility tree access.
176 virtual AXObject* computeParent() const override; 177 virtual AXObject* computeParent() const override;
177 virtual AXObject* computeParentIfExists() const override; 178 virtual AXObject* computeParentIfExists() const override;
178 179
179 // Low-level accessibility tree exploration. 180 // Low-level accessibility tree exploration.
180 virtual AXObject* firstChild() const override; 181 virtual AXObject* firstChild() const override;
(...skipping 21 matching lines...) Expand all
202 virtual void updateAccessibilityRole() override final; 203 virtual void updateAccessibilityRole() override final;
203 204
204 // Position in set and Size of set 205 // Position in set and Size of set
205 virtual int posInSet() const override; 206 virtual int posInSet() const override;
206 virtual int setSize() const override; 207 virtual int setSize() const override;
207 208
208 // Aria-owns. 209 // Aria-owns.
209 void computeAriaOwnsChildren(Vector<AXObject*>& ownedChildren); 210 void computeAriaOwnsChildren(Vector<AXObject*>& ownedChildren);
210 211
211 private: 212 private:
212 Node* m_node; 213 RawPtrWillBeWeakMember<Node> m_node;
haraken 2015/06/24 13:27:20 Member.
keishi 2015/06/24 15:05:26 Done.
213 214
214 String alternativeTextForWebArea() const; 215 String alternativeTextForWebArea() const;
215 void alternativeText(WillBeHeapVector<OwnPtrWillBeMember<AccessibilityText>> &) const; 216 void alternativeText(WillBeHeapVector<OwnPtrWillBeMember<AccessibilityText>> &) const;
216 void ariaLabeledByText(WillBeHeapVector<OwnPtrWillBeMember<AccessibilityText >>&) const; 217 void ariaLabeledByText(WillBeHeapVector<OwnPtrWillBeMember<AccessibilityText >>&) const;
217 float stepValueForRange() const; 218 float stepValueForRange() const;
218 AXObject* findChildWithTagName(const HTMLQualifiedName&) const; 219 AXObject* findChildWithTagName(const HTMLQualifiedName&) const;
219 bool isDescendantOfElementType(const HTMLQualifiedName& tagName) const; 220 bool isDescendantOfElementType(const HTMLQualifiedName& tagName) const;
220 }; 221 };
221 222
222 DEFINE_AX_OBJECT_TYPE_CASTS(AXNodeObject, isAXNodeObject()); 223 DEFINE_AX_OBJECT_TYPE_CASTS(AXNodeObject, isAXNodeObject());
223 224
224 } // namespace blink 225 } // namespace blink
225 226
226 #endif // AXNodeObject_h 227 #endif // AXNodeObject_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698