OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
3 * Copyright (C) 2013 Apple Inc. All rights reserved. | 3 * Copyright (C) 2013 Apple Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * | 8 * |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 #include "core/inspector/ConsoleMessageStorage.h" | 96 #include "core/inspector/ConsoleMessageStorage.h" |
97 #include "core/inspector/InspectorClient.h" | 97 #include "core/inspector/InspectorClient.h" |
98 #include "core/inspector/InspectorConsoleAgent.h" | 98 #include "core/inspector/InspectorConsoleAgent.h" |
99 #include "core/inspector/InspectorController.h" | 99 #include "core/inspector/InspectorController.h" |
100 #include "core/inspector/InspectorCounters.h" | 100 #include "core/inspector/InspectorCounters.h" |
101 #include "core/inspector/InspectorFrontendChannel.h" | 101 #include "core/inspector/InspectorFrontendChannel.h" |
102 #include "core/inspector/InspectorInstrumentation.h" | 102 #include "core/inspector/InspectorInstrumentation.h" |
103 #include "core/inspector/InspectorOverlay.h" | 103 #include "core/inspector/InspectorOverlay.h" |
104 #include "core/inspector/InstrumentingAgents.h" | 104 #include "core/inspector/InstrumentingAgents.h" |
105 #include "core/layout/Layer.h" | 105 #include "core/layout/Layer.h" |
| 106 #include "core/layout/LayoutMenuList.h" |
106 #include "core/layout/LayoutObject.h" | 107 #include "core/layout/LayoutObject.h" |
107 #include "core/layout/LayoutTreeAsText.h" | 108 #include "core/layout/LayoutTreeAsText.h" |
108 #include "core/layout/LayoutView.h" | 109 #include "core/layout/LayoutView.h" |
109 #include "core/layout/compositing/CompositedLayerMapping.h" | 110 #include "core/layout/compositing/CompositedLayerMapping.h" |
110 #include "core/layout/compositing/LayerCompositor.h" | 111 #include "core/layout/compositing/LayerCompositor.h" |
111 #include "core/loader/FrameLoader.h" | 112 #include "core/loader/FrameLoader.h" |
112 #include "core/loader/HistoryItem.h" | 113 #include "core/loader/HistoryItem.h" |
113 #include "core/page/Chrome.h" | 114 #include "core/page/Chrome.h" |
114 #include "core/page/ChromeClient.h" | 115 #include "core/page/ChromeClient.h" |
115 #include "core/page/EventHandler.h" | 116 #include "core/page/EventHandler.h" |
116 #include "core/page/FocusController.h" | 117 #include "core/page/FocusController.h" |
117 #include "core/page/NetworkStateNotifier.h" | 118 #include "core/page/NetworkStateNotifier.h" |
118 #include "core/page/Page.h" | 119 #include "core/page/Page.h" |
119 #include "core/page/PrintContext.h" | 120 #include "core/page/PrintContext.h" |
120 #include "core/plugins/testing/DictionaryPluginPlaceholder.h" | 121 #include "core/plugins/testing/DictionaryPluginPlaceholder.h" |
121 #include "core/plugins/testing/DocumentFragmentPluginPlaceholder.h" | 122 #include "core/plugins/testing/DocumentFragmentPluginPlaceholder.h" |
122 #include "core/rendering/RenderMenuList.h" | |
123 #include "core/testing/DictionaryTest.h" | 123 #include "core/testing/DictionaryTest.h" |
124 #include "core/testing/GCObservation.h" | 124 #include "core/testing/GCObservation.h" |
125 #include "core/testing/InternalSettings.h" | 125 #include "core/testing/InternalSettings.h" |
126 #include "core/testing/LayerRect.h" | 126 #include "core/testing/LayerRect.h" |
127 #include "core/testing/LayerRectList.h" | 127 #include "core/testing/LayerRectList.h" |
128 #include "core/testing/PluginPlaceholderOptions.h" | 128 #include "core/testing/PluginPlaceholderOptions.h" |
129 #include "core/testing/PrivateScriptTest.h" | 129 #include "core/testing/PrivateScriptTest.h" |
130 #include "core/testing/TypeConversions.h" | 130 #include "core/testing/TypeConversions.h" |
131 #include "core/testing/UnionTypesTest.h" | 131 #include "core/testing/UnionTypesTest.h" |
132 #include "core/workers/WorkerThread.h" | 132 #include "core/workers/WorkerThread.h" |
(...skipping 1865 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1998 ASSERT(node); | 1998 ASSERT(node); |
1999 if (!isHTMLSelectElement(*node)) | 1999 if (!isHTMLSelectElement(*node)) |
2000 return false; | 2000 return false; |
2001 | 2001 |
2002 HTMLSelectElement& select = toHTMLSelectElement(*node); | 2002 HTMLSelectElement& select = toHTMLSelectElement(*node); |
2003 | 2003 |
2004 LayoutObject* renderer = select.renderer(); | 2004 LayoutObject* renderer = select.renderer(); |
2005 if (!renderer || !renderer->isMenuList()) | 2005 if (!renderer || !renderer->isMenuList()) |
2006 return false; | 2006 return false; |
2007 | 2007 |
2008 RenderMenuList* menuList = toRenderMenuList(renderer); | 2008 LayoutMenuList* menuList = toLayoutMenuList(renderer); |
2009 return menuList->popupIsVisible(); | 2009 return menuList->popupIsVisible(); |
2010 } | 2010 } |
2011 | 2011 |
2012 bool Internals::selectPopupItemStyleIsRtl(Node* node, int itemIndex) | 2012 bool Internals::selectPopupItemStyleIsRtl(Node* node, int itemIndex) |
2013 { | 2013 { |
2014 if (!node || !isHTMLSelectElement(*node)) | 2014 if (!node || !isHTMLSelectElement(*node)) |
2015 return false; | 2015 return false; |
2016 | 2016 |
2017 HTMLSelectElement& select = toHTMLSelectElement(*node); | 2017 HTMLSelectElement& select = toHTMLSelectElement(*node); |
2018 | 2018 |
2019 LayoutObject* renderer = select.renderer(); | 2019 LayoutObject* renderer = select.renderer(); |
2020 if (!renderer || !renderer->isMenuList()) | 2020 if (!renderer || !renderer->isMenuList()) |
2021 return false; | 2021 return false; |
2022 | 2022 |
2023 RenderMenuList& menuList = toRenderMenuList(*renderer); | 2023 LayoutMenuList& menuList = toLayoutMenuList(*renderer); |
2024 PopupMenuStyle itemStyle = menuList.itemStyle(itemIndex); | 2024 PopupMenuStyle itemStyle = menuList.itemStyle(itemIndex); |
2025 return itemStyle.textDirection() == RTL; | 2025 return itemStyle.textDirection() == RTL; |
2026 } | 2026 } |
2027 | 2027 |
2028 int Internals::selectPopupItemStyleFontHeight(Node* node, int itemIndex) | 2028 int Internals::selectPopupItemStyleFontHeight(Node* node, int itemIndex) |
2029 { | 2029 { |
2030 if (!node || !isHTMLSelectElement(*node)) | 2030 if (!node || !isHTMLSelectElement(*node)) |
2031 return false; | 2031 return false; |
2032 | 2032 |
2033 HTMLSelectElement& select = toHTMLSelectElement(*node); | 2033 HTMLSelectElement& select = toHTMLSelectElement(*node); |
2034 | 2034 |
2035 LayoutObject* renderer = select.renderer(); | 2035 LayoutObject* renderer = select.renderer(); |
2036 if (!renderer || !renderer->isMenuList()) | 2036 if (!renderer || !renderer->isMenuList()) |
2037 return false; | 2037 return false; |
2038 | 2038 |
2039 RenderMenuList& menuList = toRenderMenuList(*renderer); | 2039 LayoutMenuList& menuList = toLayoutMenuList(*renderer); |
2040 PopupMenuStyle itemStyle = menuList.itemStyle(itemIndex); | 2040 PopupMenuStyle itemStyle = menuList.itemStyle(itemIndex); |
2041 return itemStyle.font().fontMetrics().height(); | 2041 return itemStyle.font().fontMetrics().height(); |
2042 } | 2042 } |
2043 | 2043 |
2044 bool Internals::loseSharedGraphicsContext3D() | 2044 bool Internals::loseSharedGraphicsContext3D() |
2045 { | 2045 { |
2046 OwnPtr<blink::WebGraphicsContext3DProvider> sharedProvider = adoptPtr(blink:
:Platform::current()->createSharedOffscreenGraphicsContext3DProvider()); | 2046 OwnPtr<blink::WebGraphicsContext3DProvider> sharedProvider = adoptPtr(blink:
:Platform::current()->createSharedOffscreenGraphicsContext3DProvider()); |
2047 if (!sharedProvider) | 2047 if (!sharedProvider) |
2048 return false; | 2048 return false; |
2049 blink::WebGraphicsContext3D* sharedContext = sharedProvider->context3d(); | 2049 blink::WebGraphicsContext3D* sharedContext = sharedProvider->context3d(); |
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2322 { | 2322 { |
2323 ThreadState::current()->schedulePreciseGC(); | 2323 ThreadState::current()->schedulePreciseGC(); |
2324 } | 2324 } |
2325 | 2325 |
2326 ValueIterable<int>::IterationSource* Internals::startIteration(ScriptState*, Exc
eptionState&) | 2326 ValueIterable<int>::IterationSource* Internals::startIteration(ScriptState*, Exc
eptionState&) |
2327 { | 2327 { |
2328 return new InternalsIterationSource(); | 2328 return new InternalsIterationSource(); |
2329 } | 2329 } |
2330 | 2330 |
2331 } // namespace blink | 2331 } // namespace blink |
OLD | NEW |