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

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

Issue 22331005: Clean up accessibility enums for use in Chromium. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: reupload Created 7 years, 4 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) 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2008 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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 58
59 if (!m_mapElement.get() || !m_mapElement->renderer()) 59 if (!m_mapElement.get() || !m_mapElement->renderer())
60 return 0; 60 return 0;
61 61
62 return m_mapElement->document()->axObjectCache()->getOrCreate(m_mapElement-> renderer()); 62 return m_mapElement->document()->axObjectCache()->getOrCreate(m_mapElement-> renderer());
63 } 63 }
64 64
65 AccessibilityRole AccessibilityImageMapLink::roleValue() const 65 AccessibilityRole AccessibilityImageMapLink::roleValue() const
66 { 66 {
67 if (!m_areaElement) 67 if (!m_areaElement)
68 return WebCoreLinkRole; 68 return LinkRole;
69 69
70 const AtomicString& ariaRole = getAttribute(roleAttr); 70 const AtomicString& ariaRole = getAttribute(roleAttr);
71 if (!ariaRole.isEmpty()) 71 if (!ariaRole.isEmpty())
72 return AccessibilityObject::ariaRoleToWebCoreRole(ariaRole); 72 return AccessibilityObject::ariaRoleToWebCoreRole(ariaRole);
73 73
74 return WebCoreLinkRole; 74 return LinkRole;
75 } 75 }
76 76
77 Element* AccessibilityImageMapLink::actionElement() const 77 Element* AccessibilityImageMapLink::actionElement() const
78 { 78 {
79 return anchorElement(); 79 return anchorElement();
80 } 80 }
81 81
82 Element* AccessibilityImageMapLink::anchorElement() const 82 Element* AccessibilityImageMapLink::anchorElement() const
83 { 83 {
84 return m_areaElement.get(); 84 return m_areaElement.get();
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 else 142 else
143 renderer = m_mapElement->renderer(); 143 renderer = m_mapElement->renderer();
144 144
145 if (!renderer) 145 if (!renderer)
146 return LayoutRect(); 146 return LayoutRect();
147 147
148 return m_areaElement->computeRect(renderer); 148 return m_areaElement->computeRect(renderer);
149 } 149 }
150 150
151 } // namespace WebCore 151 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698