| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 20 matching lines...) Expand all Loading... |
| 31 | 31 |
| 32 #include "core/inspector/InspectorDOMAgent.h" | 32 #include "core/inspector/InspectorDOMAgent.h" |
| 33 #include "core/inspector/InspectorOverlayHost.h" | 33 #include "core/inspector/InspectorOverlayHost.h" |
| 34 #include "platform/Timer.h" | 34 #include "platform/Timer.h" |
| 35 #include "platform/geometry/FloatQuad.h" | 35 #include "platform/geometry/FloatQuad.h" |
| 36 #include "platform/geometry/LayoutRect.h" | 36 #include "platform/geometry/LayoutRect.h" |
| 37 #include "platform/graphics/Color.h" | 37 #include "platform/graphics/Color.h" |
| 38 #include "platform/heap/Handle.h" | 38 #include "platform/heap/Handle.h" |
| 39 #include "platform/inspector_protocol/Values.h" | 39 #include "platform/inspector_protocol/Values.h" |
| 40 #include "public/web/WebInputEvent.h" | 40 #include "public/web/WebInputEvent.h" |
| 41 #include "wtf/OwnPtr.h" |
| 42 #include "wtf/PassOwnPtr.h" |
| 41 #include "wtf/RefPtr.h" | 43 #include "wtf/RefPtr.h" |
| 42 #include "wtf/text/WTFString.h" | 44 #include "wtf/text/WTFString.h" |
| 43 #include <memory> | |
| 44 | 45 |
| 45 namespace blink { | 46 namespace blink { |
| 46 | 47 |
| 47 class Color; | 48 class Color; |
| 48 class EmptyChromeClient; | 49 class EmptyChromeClient; |
| 49 class LocalFrame; | 50 class LocalFrame; |
| 50 class GraphicsContext; | 51 class GraphicsContext; |
| 51 class GraphicsLayer; | 52 class GraphicsLayer; |
| 52 class InspectorCSSAgent; | 53 class InspectorCSSAgent; |
| 53 class LayoutEditor; | 54 class LayoutEditor; |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 102 void overlayStartedPropertyChange(const String&) override; | 103 void overlayStartedPropertyChange(const String&) override; |
| 103 void overlayPropertyChanged(float) override; | 104 void overlayPropertyChanged(float) override; |
| 104 void overlayEndedPropertyChange() override; | 105 void overlayEndedPropertyChange() override; |
| 105 void overlayClearSelection(bool) override; | 106 void overlayClearSelection(bool) override; |
| 106 void overlayNextSelector() override; | 107 void overlayNextSelector() override; |
| 107 void overlayPreviousSelector() override; | 108 void overlayPreviousSelector() override; |
| 108 | 109 |
| 109 // InspectorDOMAgent::Client implementation. | 110 // InspectorDOMAgent::Client implementation. |
| 110 void hideHighlight() override; | 111 void hideHighlight() override; |
| 111 void highlightNode(Node*, const InspectorHighlightConfig&, bool omitTooltip)
override; | 112 void highlightNode(Node*, const InspectorHighlightConfig&, bool omitTooltip)
override; |
| 112 void highlightQuad(std::unique_ptr<FloatQuad>, const InspectorHighlightConfi
g&) override; | 113 void highlightQuad(PassOwnPtr<FloatQuad>, const InspectorHighlightConfig&) o
verride; |
| 113 void setInspectMode(InspectorDOMAgent::SearchMode, std::unique_ptr<Inspector
HighlightConfig>) override; | 114 void setInspectMode(InspectorDOMAgent::SearchMode, PassOwnPtr<InspectorHighl
ightConfig>) override; |
| 114 void setInspectedNode(Node*) override; | 115 void setInspectedNode(Node*) override; |
| 115 | 116 |
| 116 void highlightNode(Node*, Node* eventTarget, const InspectorHighlightConfig&
, bool omitTooltip); | 117 void highlightNode(Node*, Node* eventTarget, const InspectorHighlightConfig&
, bool omitTooltip); |
| 117 bool isEmpty(); | 118 bool isEmpty(); |
| 118 void drawNodeHighlight(); | 119 void drawNodeHighlight(); |
| 119 void drawQuadHighlight(); | 120 void drawQuadHighlight(); |
| 120 void drawPausedInDebuggerMessage(); | 121 void drawPausedInDebuggerMessage(); |
| 121 void drawViewSize(); | 122 void drawViewSize(); |
| 122 | 123 |
| 123 Page* overlayPage(); | 124 Page* overlayPage(); |
| (...skipping 13 matching lines...) Expand all Loading... |
| 137 bool handleMouseMove(const PlatformMouseEvent&); | 138 bool handleMouseMove(const PlatformMouseEvent&); |
| 138 bool shouldSearchForNode(); | 139 bool shouldSearchForNode(); |
| 139 void inspect(Node*); | 140 void inspect(Node*); |
| 140 void initializeLayoutEditorIfNeeded(Node*); | 141 void initializeLayoutEditorIfNeeded(Node*); |
| 141 | 142 |
| 142 WebViewImpl* m_webViewImpl; | 143 WebViewImpl* m_webViewImpl; |
| 143 String m_pausedInDebuggerMessage; | 144 String m_pausedInDebuggerMessage; |
| 144 Member<Node> m_highlightNode; | 145 Member<Node> m_highlightNode; |
| 145 Member<Node> m_eventTargetNode; | 146 Member<Node> m_eventTargetNode; |
| 146 InspectorHighlightConfig m_nodeHighlightConfig; | 147 InspectorHighlightConfig m_nodeHighlightConfig; |
| 147 std::unique_ptr<FloatQuad> m_highlightQuad; | 148 OwnPtr<FloatQuad> m_highlightQuad; |
| 148 Member<Page> m_overlayPage; | 149 Member<Page> m_overlayPage; |
| 149 Member<InspectorOverlayChromeClient> m_overlayChromeClient; | 150 Member<InspectorOverlayChromeClient> m_overlayChromeClient; |
| 150 Member<InspectorOverlayHost> m_overlayHost; | 151 Member<InspectorOverlayHost> m_overlayHost; |
| 151 InspectorHighlightConfig m_quadHighlightConfig; | 152 InspectorHighlightConfig m_quadHighlightConfig; |
| 152 bool m_drawViewSize; | 153 bool m_drawViewSize; |
| 153 bool m_resizeTimerActive; | 154 bool m_resizeTimerActive; |
| 154 bool m_omitTooltip; | 155 bool m_omitTooltip; |
| 155 Timer<InspectorOverlay> m_timer; | 156 Timer<InspectorOverlay> m_timer; |
| 156 int m_suspendCount; | 157 int m_suspendCount; |
| 157 bool m_inLayout; | 158 bool m_inLayout; |
| 158 bool m_needsUpdate; | 159 bool m_needsUpdate; |
| 159 V8InspectorSession* m_v8Session; | 160 V8InspectorSession* m_v8Session; |
| 160 Member<InspectorDOMAgent> m_domAgent; | 161 Member<InspectorDOMAgent> m_domAgent; |
| 161 Member<InspectorCSSAgent> m_cssAgent; | 162 Member<InspectorCSSAgent> m_cssAgent; |
| 162 Member<LayoutEditor> m_layoutEditor; | 163 Member<LayoutEditor> m_layoutEditor; |
| 163 std::unique_ptr<PageOverlay> m_pageOverlay; | 164 OwnPtr<PageOverlay> m_pageOverlay; |
| 164 Member<Node> m_hoveredNodeForInspectMode; | 165 Member<Node> m_hoveredNodeForInspectMode; |
| 165 InspectorDOMAgent::SearchMode m_inspectMode; | 166 InspectorDOMAgent::SearchMode m_inspectMode; |
| 166 std::unique_ptr<InspectorHighlightConfig> m_inspectModeHighlightConfig; | 167 OwnPtr<InspectorHighlightConfig> m_inspectModeHighlightConfig; |
| 167 }; | 168 }; |
| 168 | 169 |
| 169 } // namespace blink | 170 } // namespace blink |
| 170 | 171 |
| 171 | 172 |
| 172 #endif // InspectorOverlay_h | 173 #endif // InspectorOverlay_h |
| OLD | NEW |