| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ |
| 6 #define CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ | 6 #define CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 #include "content/public/common/referrer.h" | 38 #include "content/public/common/referrer.h" |
| 39 #include "content/public/common/renderer_preferences.h" | 39 #include "content/public/common/renderer_preferences.h" |
| 40 #include "content/public/common/top_controls_state.h" | 40 #include "content/public/common/top_controls_state.h" |
| 41 #include "content/public/common/web_preferences.h" | 41 #include "content/public/common/web_preferences.h" |
| 42 #include "content/public/renderer/render_view.h" | 42 #include "content/public/renderer/render_view.h" |
| 43 #include "content/renderer/render_frame_impl.h" | 43 #include "content/renderer/render_frame_impl.h" |
| 44 #include "content/renderer/render_widget.h" | 44 #include "content/renderer/render_widget.h" |
| 45 #include "content/renderer/render_widget_owner_delegate.h" | 45 #include "content/renderer/render_widget_owner_delegate.h" |
| 46 #include "content/renderer/stats_collection_observer.h" | 46 #include "content/renderer/stats_collection_observer.h" |
| 47 #include "ipc/ipc_platform_file.h" | 47 #include "ipc/ipc_platform_file.h" |
| 48 #include "third_party/WebKit/public/platform/WebPageVisibilityState.h" | |
| 49 #include "third_party/WebKit/public/platform/WebSecurityOrigin.h" | 48 #include "third_party/WebKit/public/platform/WebSecurityOrigin.h" |
| 50 #include "third_party/WebKit/public/web/WebAXObject.h" | 49 #include "third_party/WebKit/public/web/WebAXObject.h" |
| 51 #include "third_party/WebKit/public/web/WebConsoleMessage.h" | 50 #include "third_party/WebKit/public/web/WebConsoleMessage.h" |
| 52 #include "third_party/WebKit/public/web/WebDataSource.h" | 51 #include "third_party/WebKit/public/web/WebDataSource.h" |
| 53 #include "third_party/WebKit/public/web/WebElement.h" | 52 #include "third_party/WebKit/public/web/WebElement.h" |
| 54 #include "third_party/WebKit/public/web/WebFrameWidget.h" | 53 #include "third_party/WebKit/public/web/WebFrameWidget.h" |
| 55 #include "third_party/WebKit/public/web/WebHistoryItem.h" | 54 #include "third_party/WebKit/public/web/WebHistoryItem.h" |
| 56 #include "third_party/WebKit/public/web/WebIconURL.h" | 55 #include "third_party/WebKit/public/web/WebIconURL.h" |
| 57 #include "third_party/WebKit/public/web/WebInputEvent.h" | 56 #include "third_party/WebKit/public/web/WebInputEvent.h" |
| 58 #include "third_party/WebKit/public/web/WebNavigationType.h" | 57 #include "third_party/WebKit/public/web/WebNavigationType.h" |
| (...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 375 blink::WebString acceptLanguages() override; | 374 blink::WebString acceptLanguages() override; |
| 376 void navigateBackForwardSoon(int offset) override; | 375 void navigateBackForwardSoon(int offset) override; |
| 377 int historyBackListCount() override; | 376 int historyBackListCount() override; |
| 378 int historyForwardListCount() override; | 377 int historyForwardListCount() override; |
| 379 blink::WebSpeechRecognizer* speechRecognizer() override; | 378 blink::WebSpeechRecognizer* speechRecognizer() override; |
| 380 void zoomLimitsChanged(double minimum_level, double maximum_level) override; | 379 void zoomLimitsChanged(double minimum_level, double maximum_level) override; |
| 381 virtual void zoomLevelChanged(); | 380 virtual void zoomLevelChanged(); |
| 382 void pageScaleFactorChanged() override; | 381 void pageScaleFactorChanged() override; |
| 383 virtual double zoomLevelToZoomFactor(double zoom_level) const; | 382 virtual double zoomLevelToZoomFactor(double zoom_level) const; |
| 384 virtual double zoomFactorToZoomLevel(double factor) const; | 383 virtual double zoomFactorToZoomLevel(double factor) const; |
| 385 blink::WebPageVisibilityState visibilityState() const override; | |
| 386 void draggableRegionsChanged() override; | 384 void draggableRegionsChanged() override; |
| 387 void pageImportanceSignalsChanged() override; | 385 void pageImportanceSignalsChanged() override; |
| 388 | 386 |
| 389 #if defined(OS_ANDROID) | 387 #if defined(OS_ANDROID) |
| 390 void scheduleContentIntent(const blink::WebURL& intent, | 388 void scheduleContentIntent(const blink::WebURL& intent, |
| 391 bool is_main_frame) override; | 389 bool is_main_frame) override; |
| 392 void cancelScheduledContentIntents() override; | 390 void cancelScheduledContentIntents() override; |
| 393 blink::WebContentDetectionResult detectContentAround( | 391 blink::WebContentDetectionResult detectContentAround( |
| 394 const blink::WebHitTestResult& touch_hit) override; | 392 const blink::WebHitTestResult& touch_hit) override; |
| 395 | 393 |
| (...skipping 12 matching lines...) Expand all Loading... |
| 408 int GetRoutingID() const override; | 406 int GetRoutingID() const override; |
| 409 gfx::Size GetSize() const override; | 407 gfx::Size GetSize() const override; |
| 410 float GetDeviceScaleFactor() const override; | 408 float GetDeviceScaleFactor() const override; |
| 411 WebPreferences& GetWebkitPreferences() override; | 409 WebPreferences& GetWebkitPreferences() override; |
| 412 void SetWebkitPreferences(const WebPreferences& preferences) override; | 410 void SetWebkitPreferences(const WebPreferences& preferences) override; |
| 413 blink::WebView* GetWebView() override; | 411 blink::WebView* GetWebView() override; |
| 414 blink::WebFrameWidget* GetWebFrameWidget() override; | 412 blink::WebFrameWidget* GetWebFrameWidget() override; |
| 415 bool ShouldDisplayScrollbars(int width, int height) const override; | 413 bool ShouldDisplayScrollbars(int width, int height) const override; |
| 416 int GetEnabledBindings() const override; | 414 int GetEnabledBindings() const override; |
| 417 bool GetContentStateImmediately() const override; | 415 bool GetContentStateImmediately() const override; |
| 418 blink::WebPageVisibilityState GetVisibilityState() const override; | |
| 419 void DidStartLoading() override; | 416 void DidStartLoading() override; |
| 420 void DidStopLoading() override; | 417 void DidStopLoading() override; |
| 421 void Repaint(const gfx::Size& size) override; | 418 void Repaint(const gfx::Size& size) override; |
| 422 void SetEditCommandForNextKeyEvent(const std::string& name, | 419 void SetEditCommandForNextKeyEvent(const std::string& name, |
| 423 const std::string& value) override; | 420 const std::string& value) override; |
| 424 void ClearEditCommands() override; | 421 void ClearEditCommands() override; |
| 425 SSLStatus GetSSLStatusOfFrame(blink::WebFrame* frame) const override; | 422 SSLStatus GetSSLStatusOfFrame(blink::WebFrame* frame) const override; |
| 426 const std::string& GetAcceptLanguages() const override; | 423 const std::string& GetAcceptLanguages() const override; |
| 427 #if defined(OS_ANDROID) | 424 #if defined(OS_ANDROID) |
| 428 void UpdateTopControlsState(TopControlsState constraints, | 425 void UpdateTopControlsState(TopControlsState constraints, |
| (...skipping 12 matching lines...) Expand all Loading... |
| 441 // Please do not add your stuff randomly to the end here. If there is an | 438 // Please do not add your stuff randomly to the end here. If there is an |
| 442 // appropriate section, add it there. If not, there are some random functions | 439 // appropriate section, add it there. If not, there are some random functions |
| 443 // nearer to the top you can add it to. | 440 // nearer to the top you can add it to. |
| 444 | 441 |
| 445 protected: | 442 protected: |
| 446 // RenderWidget overrides: | 443 // RenderWidget overrides: |
| 447 void CloseForFrame() override; | 444 void CloseForFrame() override; |
| 448 void Close() override; | 445 void Close() override; |
| 449 void OnResize(const ResizeParams& params) override; | 446 void OnResize(const ResizeParams& params) override; |
| 450 void OnSetFocus(bool enable) override; | 447 void OnSetFocus(bool enable) override; |
| 451 void OnWasHidden() override; | |
| 452 void OnWasShown(bool needs_repainting, | |
| 453 const ui::LatencyInfo& latency_info) override; | |
| 454 GURL GetURLForGraphicsContext3D() override; | 448 GURL GetURLForGraphicsContext3D() override; |
| 455 void OnImeSetComposition( | 449 void OnImeSetComposition( |
| 456 const base::string16& text, | 450 const base::string16& text, |
| 457 const std::vector<blink::WebCompositionUnderline>& underlines, | 451 const std::vector<blink::WebCompositionUnderline>& underlines, |
| 458 const gfx::Range& replacement_range, | 452 const gfx::Range& replacement_range, |
| 459 int selection_start, | 453 int selection_start, |
| 460 int selection_end) override; | 454 int selection_end) override; |
| 461 void OnImeConfirmComposition(const base::string16& text, | 455 void OnImeConfirmComposition(const base::string16& text, |
| 462 const gfx::Range& replacement_range, | 456 const gfx::Range& replacement_range, |
| 463 bool keep_selection) override; | 457 bool keep_selection) override; |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 665 bool enable_showing, | 659 bool enable_showing, |
| 666 bool animate); | 660 bool animate); |
| 667 void OnExtractSmartClipData(const gfx::Rect& rect); | 661 void OnExtractSmartClipData(const gfx::Rect& rect); |
| 668 #elif defined(OS_MACOSX) | 662 #elif defined(OS_MACOSX) |
| 669 void OnGetRenderedText(); | 663 void OnGetRenderedText(); |
| 670 #endif | 664 #endif |
| 671 | 665 |
| 672 // Page message handlers ----------------------------------------------------- | 666 // Page message handlers ----------------------------------------------------- |
| 673 void OnUpdateWindowScreenRect(gfx::Rect window_screen_rect); | 667 void OnUpdateWindowScreenRect(gfx::Rect window_screen_rect); |
| 674 void OnSetZoomLevel(PageMsg_SetZoomLevel_Command command, double zoom_level); | 668 void OnSetZoomLevel(PageMsg_SetZoomLevel_Command command, double zoom_level); |
| 669 void OnPageWasHidden(); |
| 670 void OnPageWasShown(); |
| 675 | 671 |
| 676 // Adding a new message handler? Please add it in alphabetical order above | 672 // Adding a new message handler? Please add it in alphabetical order above |
| 677 // and put it in the same position in the .cc file. | 673 // and put it in the same position in the .cc file. |
| 678 | 674 |
| 679 // Misc private functions ---------------------------------------------------- | 675 // Misc private functions ---------------------------------------------------- |
| 680 // Check whether the preferred size has changed. | 676 // Check whether the preferred size has changed. |
| 681 void CheckPreferredSize(); | 677 void CheckPreferredSize(); |
| 682 | 678 |
| 683 #if defined(OS_ANDROID) | 679 #if defined(OS_ANDROID) |
| 684 // Launch an Android content intent with the given URL. | 680 // Launch an Android content intent with the given URL. |
| (...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 945 // use the Observer interface to filter IPC messages and receive frame change | 941 // use the Observer interface to filter IPC messages and receive frame change |
| 946 // notifications. | 942 // notifications. |
| 947 // --------------------------------------------------------------------------- | 943 // --------------------------------------------------------------------------- |
| 948 | 944 |
| 949 DISALLOW_COPY_AND_ASSIGN(RenderViewImpl); | 945 DISALLOW_COPY_AND_ASSIGN(RenderViewImpl); |
| 950 }; | 946 }; |
| 951 | 947 |
| 952 } // namespace content | 948 } // namespace content |
| 953 | 949 |
| 954 #endif // CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ | 950 #endif // CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ |
| OLD | NEW |