OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2014, Google Inc. All rights reserved. | 2 * Copyright (C) 2014, 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 153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
164 void setNodeInUse(Node* n) { m_textMarkerNodes.add(n); } | 164 void setNodeInUse(Node* n) { m_textMarkerNodes.add(n); } |
165 void removeNodeForUse(Node* n) { m_textMarkerNodes.remove(n); } | 165 void removeNodeForUse(Node* n) { m_textMarkerNodes.remove(n); } |
166 bool isNodeInUse(Node* n) { return m_textMarkerNodes.contains(n); } | 166 bool isNodeInUse(Node* n) { return m_textMarkerNodes.contains(n); } |
167 | 167 |
168 PassRefPtr<AXObject> createFromRenderer(RenderObject*); | 168 PassRefPtr<AXObject> createFromRenderer(RenderObject*); |
169 PassRefPtr<AXObject> createFromNode(Node*); | 169 PassRefPtr<AXObject> createFromNode(Node*); |
170 PassRefPtr<AXObject> createFromInlineTextBox(AbstractInlineTextBox*); | 170 PassRefPtr<AXObject> createFromInlineTextBox(AbstractInlineTextBox*); |
171 | 171 |
172 private: | 172 private: |
173 Document& m_document; | 173 Document& m_document; |
174 HashMap<AXID, RefPtr<AXObject> > m_objects; | 174 HashMap<AXID, RefPtr<AXObject>> m_objects; |
175 HashMap<RenderObject*, AXID> m_renderObjectMapping; | 175 HashMap<RenderObject*, AXID> m_renderObjectMapping; |
176 HashMap<Widget*, AXID> m_widgetObjectMapping; | 176 HashMap<Widget*, AXID> m_widgetObjectMapping; |
177 HashMap<Node*, AXID> m_nodeObjectMapping; | 177 HashMap<Node*, AXID> m_nodeObjectMapping; |
178 HashMap<AbstractInlineTextBox*, AXID> m_inlineTextBoxObjectMapping; | 178 HashMap<AbstractInlineTextBox*, AXID> m_inlineTextBoxObjectMapping; |
179 HashSet<Node*> m_textMarkerNodes; | 179 HashSet<Node*> m_textMarkerNodes; |
180 int m_modificationCount; | 180 int m_modificationCount; |
181 | 181 |
182 HashSet<AXID> m_idsInUse; | 182 HashSet<AXID> m_idsInUse; |
183 | 183 |
184 Timer<AXObjectCacheImpl> m_notificationPostTimer; | 184 Timer<AXObjectCacheImpl> m_notificationPostTimer; |
185 Vector<pair<RefPtr<AXObject>, AXNotification> > m_notificationsToPost; | 185 Vector<pair<RefPtr<AXObject>, AXNotification>> m_notificationsToPost; |
186 void notificationPostTimerFired(Timer<AXObjectCacheImpl>*); | 186 void notificationPostTimerFired(Timer<AXObjectCacheImpl>*); |
187 | 187 |
188 AXObject* focusedImageMapUIElement(HTMLAreaElement*); | 188 AXObject* focusedImageMapUIElement(HTMLAreaElement*); |
189 | 189 |
190 AXID getAXID(AXObject*); | 190 AXID getAXID(AXObject*); |
191 | 191 |
192 void textChanged(Node*); | 192 void textChanged(Node*); |
193 bool nodeIsTextControl(const Node*); | 193 bool nodeIsTextControl(const Node*); |
194 | 194 |
195 Settings* settings(); | 195 Settings* settings(); |
196 }; | 196 }; |
197 | 197 |
198 // This is the only subclass of AXObjectCache. | 198 // This is the only subclass of AXObjectCache. |
199 DEFINE_TYPE_CASTS(AXObjectCacheImpl, AXObjectCache, cache, true, true); | 199 DEFINE_TYPE_CASTS(AXObjectCacheImpl, AXObjectCache, cache, true, true); |
200 | 200 |
201 bool nodeHasRole(Node*, const String& role); | 201 bool nodeHasRole(Node*, const String& role); |
202 // This will let you know if aria-hidden was explicitly set to false. | 202 // This will let you know if aria-hidden was explicitly set to false. |
203 bool isNodeAriaVisible(Node*); | 203 bool isNodeAriaVisible(Node*); |
204 | 204 |
205 } | 205 } |
206 | 206 |
207 #endif | 207 #endif |
OLD | NEW |