| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 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 are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 #include "public/platform/WebString.h" | 48 #include "public/platform/WebString.h" |
| 49 #include "public/platform/WebVector.h" | 49 #include "public/platform/WebVector.h" |
| 50 #include "public/web/WebInputEvent.h" | 50 #include "public/web/WebInputEvent.h" |
| 51 #include "public/web/WebNavigationPolicy.h" | 51 #include "public/web/WebNavigationPolicy.h" |
| 52 #include "public/web/WebView.h" | 52 #include "public/web/WebView.h" |
| 53 #include "web/ChromeClientImpl.h" | 53 #include "web/ChromeClientImpl.h" |
| 54 #include "web/ContextMenuClientImpl.h" | 54 #include "web/ContextMenuClientImpl.h" |
| 55 #include "web/DragClientImpl.h" | 55 #include "web/DragClientImpl.h" |
| 56 #include "web/EditorClientImpl.h" | 56 #include "web/EditorClientImpl.h" |
| 57 #include "web/MediaKeysClientImpl.h" | 57 #include "web/MediaKeysClientImpl.h" |
| 58 #include "web/PageOverlayList.h" | |
| 59 #include "web/PageWidgetDelegate.h" | 58 #include "web/PageWidgetDelegate.h" |
| 60 #include "web/SpellCheckerClientImpl.h" | 59 #include "web/SpellCheckerClientImpl.h" |
| 61 #include "web/StorageClientImpl.h" | 60 #include "web/StorageClientImpl.h" |
| 62 #include "wtf/HashSet.h" | 61 #include "wtf/HashSet.h" |
| 63 #include "wtf/OwnPtr.h" | 62 #include "wtf/OwnPtr.h" |
| 64 #include "wtf/RefCounted.h" | 63 #include "wtf/RefCounted.h" |
| 65 #include "wtf/Vector.h" | 64 #include "wtf/Vector.h" |
| 66 | 65 |
| 67 namespace blink { | 66 namespace blink { |
| 68 | 67 |
| 69 class DataObject; | 68 class DataObject; |
| 70 class DevToolsEmulator; | 69 class DevToolsEmulator; |
| 71 class Frame; | 70 class Frame; |
| 72 class FullscreenController; | 71 class FullscreenController; |
| 73 class InspectorOverlay; | 72 class InspectorOverlay; |
| 74 class InspectorOverlayImpl; | 73 class InspectorOverlayImpl; |
| 75 class LinkHighlightImpl; | 74 class LinkHighlightImpl; |
| 75 class PageOverlay; |
| 76 class PageScaleConstraintsSet; | 76 class PageScaleConstraintsSet; |
| 77 class DeprecatedPaintLayerCompositor; | 77 class DeprecatedPaintLayerCompositor; |
| 78 class TopControls; | 78 class TopControls; |
| 79 class UserGestureToken; | 79 class UserGestureToken; |
| 80 class WebActiveGestureAnimation; | 80 class WebActiveGestureAnimation; |
| 81 class WebDevToolsAgentImpl; | 81 class WebDevToolsAgentImpl; |
| 82 class WebElement; | 82 class WebElement; |
| 83 class WebLayerTreeView; | 83 class WebLayerTreeView; |
| 84 class WebLocalFrameImpl; | 84 class WebLocalFrameImpl; |
| 85 class WebImage; | 85 class WebImage; |
| (...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 254 void disableDeviceEmulation() override; | 254 void disableDeviceEmulation() override; |
| 255 WebAXObject accessibilityObject() override; | 255 WebAXObject accessibilityObject() override; |
| 256 void setSelectionColors(unsigned activeBackgroundColor, | 256 void setSelectionColors(unsigned activeBackgroundColor, |
| 257 unsigned activeForegroundColor, | 257 unsigned activeForegroundColor, |
| 258 unsigned inactiveBackgroundColor, | 258 unsigned inactiveBackgroundColor, |
| 259 unsigned inactiveForegroundColor) override; | 259 unsigned inactiveForegroundColor) override; |
| 260 void performCustomContextMenuAction(unsigned action) override; | 260 void performCustomContextMenuAction(unsigned action) override; |
| 261 void showContextMenu() override; | 261 void showContextMenu() override; |
| 262 void extractSmartClipData(WebRect, WebString&, WebString&, WebRect&) overrid
e; | 262 void extractSmartClipData(WebRect, WebString&, WebString&, WebRect&) overrid
e; |
| 263 void hidePopups() override; | 263 void hidePopups() override; |
| 264 void addPageOverlay(WebPageOverlay*, int /* zOrder */) override; | |
| 265 void setPageOverlayColor(WebColor) override; | 264 void setPageOverlayColor(WebColor) override; |
| 266 void removePageOverlay(WebPageOverlay*) override; | |
| 267 void transferActiveWheelFlingAnimation(const WebActiveWheelFlingParameters&)
override; | 265 void transferActiveWheelFlingAnimation(const WebActiveWheelFlingParameters&)
override; |
| 268 bool endActiveFlingAnimation() override; | 266 bool endActiveFlingAnimation() override; |
| 269 void setShowPaintRects(bool) override; | 267 void setShowPaintRects(bool) override; |
| 270 void setShowDebugBorders(bool); | 268 void setShowDebugBorders(bool); |
| 271 void setShowFPSCounter(bool) override; | 269 void setShowFPSCounter(bool) override; |
| 272 void setContinuousPaintingEnabled(bool) override; | 270 void setContinuousPaintingEnabled(bool) override; |
| 273 void setShowScrollBottleneckRects(bool) override; | 271 void setShowScrollBottleneckRects(bool) override; |
| 274 void acceptLanguagesChanged() override; | 272 void acceptLanguagesChanged() override; |
| 275 | 273 |
| 276 // WebViewImpl | 274 // WebViewImpl |
| (...skipping 14 matching lines...) Expand all Loading... |
| 291 void setBackgroundColorOverride(WebColor); | 289 void setBackgroundColorOverride(WebColor); |
| 292 void setZoomFactorOverride(float); | 290 void setZoomFactorOverride(float); |
| 293 void updateShowFPSCounterAndContinuousPainting(); | 291 void updateShowFPSCounterAndContinuousPainting(); |
| 294 void setCompositorDeviceScaleFactorOverride(float); | 292 void setCompositorDeviceScaleFactorOverride(float); |
| 295 void setRootLayerTransform(const WebSize& offset, float scale); | 293 void setRootLayerTransform(const WebSize& offset, float scale); |
| 296 | 294 |
| 297 Color baseBackgroundColor() const { return m_baseBackgroundColor; } | 295 Color baseBackgroundColor() const { return m_baseBackgroundColor; } |
| 298 | 296 |
| 299 WebColor backgroundColorOverride() const { return m_backgroundColorOverride;
} | 297 WebColor backgroundColorOverride() const { return m_backgroundColorOverride;
} |
| 300 | 298 |
| 301 PageOverlayList* pageOverlays() const { return m_pageOverlays.get(); } | |
| 302 | |
| 303 void setOverlayLayer(GraphicsLayer*); | 299 void setOverlayLayer(GraphicsLayer*); |
| 304 | 300 |
| 305 const WebPoint& lastMouseDownPoint() const | 301 const WebPoint& lastMouseDownPoint() const |
| 306 { | 302 { |
| 307 return m_lastMouseDownPoint; | 303 return m_lastMouseDownPoint; |
| 308 } | 304 } |
| 309 | 305 |
| 310 Frame* focusedCoreFrame() const; | 306 Frame* focusedCoreFrame() const; |
| 311 | 307 |
| 312 // Returns the currently focused Element or null if no element has focus. | 308 // Returns the currently focused Element or null if no element has focus. |
| (...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 613 bool handleCharEvent(const WebKeyboardEvent&) override; | 609 bool handleCharEvent(const WebKeyboardEvent&) override; |
| 614 | 610 |
| 615 bool handleSyntheticWheelFromTouchpadPinchEvent(const WebGestureEvent&); | 611 bool handleSyntheticWheelFromTouchpadPinchEvent(const WebGestureEvent&); |
| 616 | 612 |
| 617 WebPlugin* focusedPluginIfInputMethodSupported(LocalFrame*); | 613 WebPlugin* focusedPluginIfInputMethodSupported(LocalFrame*); |
| 618 | 614 |
| 619 void enablePopupMouseWheelEventListener(); | 615 void enablePopupMouseWheelEventListener(); |
| 620 void disablePopupMouseWheelEventListener(); | 616 void disablePopupMouseWheelEventListener(); |
| 621 | 617 |
| 622 void cancelPagePopup(); | 618 void cancelPagePopup(); |
| 619 void updatePageOverlays(); |
| 623 | 620 |
| 624 WebViewClient* m_client; // Can be 0 (e.g. unittests, shared workers, etc.) | 621 WebViewClient* m_client; // Can be 0 (e.g. unittests, shared workers, etc.) |
| 625 WebSpellCheckClient* m_spellCheckClient; | 622 WebSpellCheckClient* m_spellCheckClient; |
| 626 | 623 |
| 627 ChromeClientImpl m_chromeClientImpl; | 624 ChromeClientImpl m_chromeClientImpl; |
| 628 ContextMenuClientImpl m_contextMenuClientImpl; | 625 ContextMenuClientImpl m_contextMenuClientImpl; |
| 629 DragClientImpl m_dragClientImpl; | 626 DragClientImpl m_dragClientImpl; |
| 630 EditorClientImpl m_editorClientImpl; | 627 EditorClientImpl m_editorClientImpl; |
| 631 SpellCheckerClientImpl m_spellCheckerClientImpl; | 628 SpellCheckerClientImpl m_spellCheckerClientImpl; |
| 632 StorageClientImpl m_storageClientImpl; | 629 StorageClientImpl m_storageClientImpl; |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 706 // The current drag operation as negotiated by the source and destination. | 703 // The current drag operation as negotiated by the source and destination. |
| 707 // When not equal to DragOperationNone, the drag data can be dropped onto th
e | 704 // When not equal to DragOperationNone, the drag data can be dropped onto th
e |
| 708 // current drop target in this WebView (the drop target can accept the drop)
. | 705 // current drop target in this WebView (the drop target can accept the drop)
. |
| 709 WebDragOperation m_dragOperation; | 706 WebDragOperation m_dragOperation; |
| 710 | 707 |
| 711 // The popup associated with an input/select element. | 708 // The popup associated with an input/select element. |
| 712 RefPtr<WebPagePopupImpl> m_pagePopup; | 709 RefPtr<WebPagePopupImpl> m_pagePopup; |
| 713 | 710 |
| 714 OwnPtrWillBePersistent<InspectorOverlayImpl> m_inspectorOverlay; | 711 OwnPtrWillBePersistent<InspectorOverlayImpl> m_inspectorOverlay; |
| 715 OwnPtrWillBePersistent<DevToolsEmulator> m_devToolsEmulator; | 712 OwnPtrWillBePersistent<DevToolsEmulator> m_devToolsEmulator; |
| 716 OwnPtr<PageOverlayList> m_pageOverlays; | 713 OwnPtr<PageOverlay> m_pageColorOverlay; |
| 717 | 714 |
| 718 // Whether the webview is rendering transparently. | 715 // Whether the webview is rendering transparently. |
| 719 bool m_isTransparent; | 716 bool m_isTransparent; |
| 720 | 717 |
| 721 // Whether the user can press tab to focus links. | 718 // Whether the user can press tab to focus links. |
| 722 bool m_tabsToLinks; | 719 bool m_tabsToLinks; |
| 723 | 720 |
| 724 // If set, the (plugin) node which has mouse capture. | 721 // If set, the (plugin) node which has mouse capture. |
| 725 RefPtrWillBePersistent<Node> m_mouseCaptureNode; | 722 RefPtrWillBePersistent<Node> m_mouseCaptureNode; |
| 726 RefPtr<UserGestureToken> m_mouseCaptureGestureToken; | 723 RefPtr<UserGestureToken> m_mouseCaptureGestureToken; |
| (...skipping 26 matching lines...) Expand all Loading... |
| 753 WebColor m_baseBackgroundColor; | 750 WebColor m_baseBackgroundColor; |
| 754 WebColor m_backgroundColorOverride; | 751 WebColor m_backgroundColorOverride; |
| 755 float m_zoomFactorOverride; | 752 float m_zoomFactorOverride; |
| 756 | 753 |
| 757 bool m_userGestureObserved; | 754 bool m_userGestureObserved; |
| 758 WebDisplayMode m_displayMode; | 755 WebDisplayMode m_displayMode; |
| 759 | 756 |
| 760 FloatSize m_elasticOverscroll; | 757 FloatSize m_elasticOverscroll; |
| 761 | 758 |
| 762 RefPtrWillBePersistent<EventListener> m_popupMouseWheelEventListener; | 759 RefPtrWillBePersistent<EventListener> m_popupMouseWheelEventListener; |
| 763 OwnPtr<WebPageOverlay> m_pageColorOverlay; | |
| 764 }; | 760 }; |
| 765 | 761 |
| 766 DEFINE_TYPE_CASTS(WebViewImpl, WebWidget, widget, widget->isWebView(), widget.is
WebView()); | 762 DEFINE_TYPE_CASTS(WebViewImpl, WebWidget, widget, widget->isWebView(), widget.is
WebView()); |
| 767 // We have no ways to check if the specified WebView is an instance of | 763 // We have no ways to check if the specified WebView is an instance of |
| 768 // WebViewImpl because WebViewImpl is the only implementation of WebView. | 764 // WebViewImpl because WebViewImpl is the only implementation of WebView. |
| 769 DEFINE_TYPE_CASTS(WebViewImpl, WebView, webView, true, true); | 765 DEFINE_TYPE_CASTS(WebViewImpl, WebView, webView, true, true); |
| 770 | 766 |
| 771 } // namespace blink | 767 } // namespace blink |
| 772 | 768 |
| 773 #endif | 769 #endif |
| OLD | NEW |