Chromium Code Reviews| Index: third_party/WebKit/public/web/WebView.h |
| diff --git a/third_party/WebKit/public/web/WebView.h b/third_party/WebKit/public/web/WebView.h |
| index dc25a387cd749060b27f5c72a40e419e5fff67f4..57a2e4f8a0fe84e3dd816900c813398f6fe18387 100644 |
| --- a/third_party/WebKit/public/web/WebView.h |
| +++ b/third_party/WebKit/public/web/WebView.h |
| @@ -69,7 +69,7 @@ struct WebPluginAction; |
| struct WebPoint; |
| struct WebWindowFeatures; |
| -class WebView : public WebWidget { |
| +class WebView : protected WebWidget { |
| public: |
| BLINK_EXPORT static const double textSizeMultiplierRatio; |
| BLINK_EXPORT static const double minTextSizeMultiplier; |
| @@ -80,6 +80,61 @@ public: |
| InjectStyleInTopFrameOnly |
| }; |
| + // WebWidget overrides. |
| + void close() override {} |
|
dcheng
2016/05/03 09:27:13
I didn't think of this for the WebWidgetClient/Web
lfg
2016/05/03 21:19:43
That does work, but it has the disadvantage of not
dcheng
2016/05/04 04:55:29
I'm OK with it either way. I don't think it's a bi
|
| + WebSize size() override { return WebSize(); } |
| + void resize(const WebSize&) override {} |
| + void resizeVisualViewport(const WebSize&) override {} |
| + void didEnterFullScreen() override {} |
| + void didExitFullScreen() override {} |
| + void beginFrame(double lastFrameTimeMonotonic) override {} |
| + void updateAllLifecyclePhases() override {} |
| + void paint(WebCanvas*, const WebRect& viewPort) override {} |
| + void paintIgnoringCompositing(WebCanvas*, const WebRect&) override {} |
| + void layoutAndPaintAsync(WebLayoutAndPaintAsyncCallback*) override {} |
| + void compositeAndReadbackAsync(WebCompositeAndReadbackAsyncCallback*) override {} |
| + void themeChanged() override {} |
| + WebInputEventResult handleInputEvent(const WebInputEvent&) override { return WebInputEventResult::NotHandled; } |
| + void setCursorVisibilityState(bool isVisible) override {} |
| + bool hasTouchEventHandlersAt(const WebPoint&) override { return true; } |
| + void applyViewportDeltas( |
| + const WebFloatSize& visualViewportDelta, |
| + const WebFloatSize& layoutViewportDelta, |
| + const WebFloatSize& elasticOverscrollDelta, |
| + float scaleFactor, |
| + float topControlsShownRatioDelta) override {} |
| + void mouseCaptureLost() override {} |
| + void setFocus(bool) override {} |
| + bool setComposition( |
| + const WebString& text, |
| + const WebVector<WebCompositionUnderline>& underlines, |
| + int selectionStart, |
| + int selectionEnd) override |
| + { |
| + return false; |
| + } |
| + bool confirmComposition() override { return false; } |
| + bool confirmComposition(ConfirmCompositionBehavior selectionBehavior) override { return false; } |
| + bool confirmComposition(const WebString& text) override { return false; } |
| + bool compositionRange(size_t* location, size_t* length) override { return false; } |
| + WebTextInputInfo textInputInfo() override { return WebTextInputInfo(); } |
| + WebTextInputType textInputType() override { return WebTextInputTypeNone; } |
| + bool selectionBounds(WebRect& anchor, WebRect& focus) const override { return false; } |
| + bool selectionTextDirection(WebTextDirection& start, WebTextDirection& end) const override { return false; } |
| + bool isSelectionAnchorFirst() const override { return false; } |
| + bool caretOrSelectionRange(size_t* location, size_t* length) override { return false; } |
| + void setTextDirection(WebTextDirection) override {} |
| + bool isAcceleratedCompositingActive() const override { return false; } |
| + bool isWebView() const override { return false; } |
| + bool isPagePopup() const override { return false; } |
| + void willCloseLayerTreeView() override {} |
| + void didAcquirePointerLock() override {} |
| + void didNotAcquirePointerLock() override {} |
| + void didLosePointerLock() override {} |
| + void didChangeWindowResizerRect() override {} |
| + WebColor backgroundColor() const override { return 0xFFFFFFFF; /* SK_ColorWHITE */ } |
| + WebPagePopup* pagePopup() const override { return 0; } |
| + void updateTopControlsState(WebTopControlsState constraints, WebTopControlsState current, bool animate) override {} |
| // Initialization ------------------------------------------------------ |
| @@ -488,6 +543,10 @@ public: |
| // context's ability to deal with that failure gracefully can be tested. |
| virtual void forceNextDrawingBufferCreationToFail() = 0; |
| + // TODO(lfg): Remove this once the refactor of WebView/WebWidget is |
| + // completed. |
| + WebWidget* widget() { return this; } |
| + |
| protected: |
| ~WebView() {} |
| }; |