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

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

Issue 966883002: renderer/RenderMenuList.* -> layout/LayoutMenuList.* (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Remove OWNERS, allowing Source/core/rendering to be deleted. Created 5 years, 9 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/core/testing/Internals.cpp ('k') | Source/modules/accessibility/AXMenuList.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) 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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 #include "core/html/HTMLTextAreaElement.h" 48 #include "core/html/HTMLTextAreaElement.h"
49 #include "core/html/shadow/ShadowElementNames.h" 49 #include "core/html/shadow/ShadowElementNames.h"
50 #include "core/layout/HitTestResult.h" 50 #include "core/layout/HitTestResult.h"
51 #include "core/layout/Layer.h" 51 #include "core/layout/Layer.h"
52 #include "core/layout/LayoutFieldset.h" 52 #include "core/layout/LayoutFieldset.h"
53 #include "core/layout/LayoutFileUploadControl.h" 53 #include "core/layout/LayoutFileUploadControl.h"
54 #include "core/layout/LayoutHTMLCanvas.h" 54 #include "core/layout/LayoutHTMLCanvas.h"
55 #include "core/layout/LayoutImage.h" 55 #include "core/layout/LayoutImage.h"
56 #include "core/layout/LayoutInline.h" 56 #include "core/layout/LayoutInline.h"
57 #include "core/layout/LayoutListMarker.h" 57 #include "core/layout/LayoutListMarker.h"
58 #include "core/layout/LayoutMenuList.h"
58 #include "core/layout/LayoutPart.h" 59 #include "core/layout/LayoutPart.h"
59 #include "core/layout/LayoutTextControlSingleLine.h" 60 #include "core/layout/LayoutTextControlSingleLine.h"
60 #include "core/layout/LayoutTextFragment.h" 61 #include "core/layout/LayoutTextFragment.h"
61 #include "core/layout/LayoutView.h" 62 #include "core/layout/LayoutView.h"
62 #include "core/loader/ProgressTracker.h" 63 #include "core/loader/ProgressTracker.h"
63 #include "core/page/Page.h" 64 #include "core/page/Page.h"
64 #include "core/rendering/RenderMenuList.h"
65 #include "core/svg/SVGDocumentExtensions.h" 65 #include "core/svg/SVGDocumentExtensions.h"
66 #include "core/svg/SVGSVGElement.h" 66 #include "core/svg/SVGSVGElement.h"
67 #include "core/svg/graphics/SVGImage.h" 67 #include "core/svg/graphics/SVGImage.h"
68 #include "modules/accessibility/AXImageMapLink.h" 68 #include "modules/accessibility/AXImageMapLink.h"
69 #include "modules/accessibility/AXInlineTextBox.h" 69 #include "modules/accessibility/AXInlineTextBox.h"
70 #include "modules/accessibility/AXObjectCacheImpl.h" 70 #include "modules/accessibility/AXObjectCacheImpl.h"
71 #include "modules/accessibility/AXSVGRoot.h" 71 #include "modules/accessibility/AXSVGRoot.h"
72 #include "modules/accessibility/AXSpinButton.h" 72 #include "modules/accessibility/AXSpinButton.h"
73 #include "modules/accessibility/AXTable.h" 73 #include "modules/accessibility/AXTable.h"
74 #include "platform/text/PlatformLocale.h" 74 #include "platform/text/PlatformLocale.h"
(...skipping 853 matching lines...) Expand 10 before | Expand all | Expand 10 after
928 String staticText = text(); 928 String staticText = text();
929 if (!staticText.length()) 929 if (!staticText.length())
930 staticText = textUnderElement(TextUnderElementAll); 930 staticText = textUnderElement(TextUnderElementAll);
931 return staticText; 931 return staticText;
932 } 932 }
933 933
934 if (m_renderer->isText()) 934 if (m_renderer->isText())
935 return textUnderElement(TextUnderElementAll); 935 return textUnderElement(TextUnderElementAll);
936 936
937 if (cssBox && cssBox->isMenuList()) { 937 if (cssBox && cssBox->isMenuList()) {
938 // RenderMenuList will go straight to the text() of its selected item. 938 // LayoutMenuList will go straight to the text() of its selected item.
939 // This has to be overridden in the case where the selected item has an ARIA label. 939 // This has to be overridden in the case where the selected item has an ARIA label.
940 HTMLSelectElement* selectElement = toHTMLSelectElement(m_renderer->node( )); 940 HTMLSelectElement* selectElement = toHTMLSelectElement(m_renderer->node( ));
941 int selectedIndex = selectElement->selectedIndex(); 941 int selectedIndex = selectElement->selectedIndex();
942 const WillBeHeapVector<RawPtrWillBeMember<HTMLElement>>& listItems = sel ectElement->listItems(); 942 const WillBeHeapVector<RawPtrWillBeMember<HTMLElement>>& listItems = sel ectElement->listItems();
943 if (selectedIndex >= 0 && static_cast<size_t>(selectedIndex) < listItems .size()) { 943 if (selectedIndex >= 0 && static_cast<size_t>(selectedIndex) < listItems .size()) {
944 const AtomicString& overriddenDescription = listItems[selectedIndex] ->fastGetAttribute(aria_labelAttr); 944 const AtomicString& overriddenDescription = listItems[selectedIndex] ->fastGetAttribute(aria_labelAttr);
945 if (!overriddenDescription.isNull()) 945 if (!overriddenDescription.isNull())
946 return overriddenDescription; 946 return overriddenDescription;
947 } 947 }
948 return toRenderMenuList(m_renderer)->text(); 948 return toLayoutMenuList(m_renderer)->text();
949 } 949 }
950 950
951 if (m_renderer->isListMarker()) 951 if (m_renderer->isListMarker())
952 return toLayoutListMarker(m_renderer)->text(); 952 return toLayoutListMarker(m_renderer)->text();
953 953
954 if (isWebArea()) { 954 if (isWebArea()) {
955 // FIXME: Why would a renderer exist when the Document isn't attached to a frame? 955 // FIXME: Why would a renderer exist when the Document isn't attached to a frame?
956 if (m_renderer->frame()) 956 if (m_renderer->frame())
957 return String(); 957 return String();
958 958
(...skipping 1452 matching lines...) Expand 10 before | Expand all | Expand 10 after
2411 if (label && label->renderer()) { 2411 if (label && label->renderer()) {
2412 LayoutRect labelRect = axObjectCache()->getOrCreate(label)->elementR ect(); 2412 LayoutRect labelRect = axObjectCache()->getOrCreate(label)->elementR ect();
2413 result.unite(labelRect); 2413 result.unite(labelRect);
2414 } 2414 }
2415 } 2415 }
2416 2416
2417 return result; 2417 return result;
2418 } 2418 }
2419 2419
2420 } // namespace blink 2420 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/testing/Internals.cpp ('k') | Source/modules/accessibility/AXMenuList.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698