| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 CHROME_RENDERER_RENDER_VIEW_H_ | 5 #ifndef CHROME_RENDERER_RENDER_VIEW_H_ |
| 6 #define CHROME_RENDERER_RENDER_VIEW_H_ | 6 #define CHROME_RENDERER_RENDER_VIEW_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <queue> | 10 #include <queue> |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 #include "gfx/point.h" | 46 #include "gfx/point.h" |
| 47 #include "gfx/rect.h" | 47 #include "gfx/rect.h" |
| 48 #include "testing/gtest/include/gtest/gtest_prod.h" | 48 #include "testing/gtest/include/gtest/gtest_prod.h" |
| 49 #include "third_party/WebKit/WebKit/chromium/public/WebAccessibilityObject.h" | 49 #include "third_party/WebKit/WebKit/chromium/public/WebAccessibilityObject.h" |
| 50 #include "third_party/WebKit/WebKit/chromium/public/WebConsoleMessage.h" | 50 #include "third_party/WebKit/WebKit/chromium/public/WebConsoleMessage.h" |
| 51 #include "third_party/WebKit/WebKit/chromium/public/WebContextMenuData.h" | 51 #include "third_party/WebKit/WebKit/chromium/public/WebContextMenuData.h" |
| 52 #include "third_party/WebKit/WebKit/chromium/public/WebFrameClient.h" | 52 #include "third_party/WebKit/WebKit/chromium/public/WebFrameClient.h" |
| 53 #include "third_party/WebKit/WebKit/chromium/public/WebMediaPlayerAction.h" | 53 #include "third_party/WebKit/WebKit/chromium/public/WebMediaPlayerAction.h" |
| 54 #include "third_party/WebKit/WebKit/chromium/public/WebNode.h" | 54 #include "third_party/WebKit/WebKit/chromium/public/WebNode.h" |
| 55 #include "third_party/WebKit/WebKit/chromium/public/WebPageSerializerClient.h" | 55 #include "third_party/WebKit/WebKit/chromium/public/WebPageSerializerClient.h" |
| 56 #include "third_party/WebKit/WebKit/chromium/public/WebPluginParams.h" |
| 56 #include "third_party/WebKit/WebKit/chromium/public/WebTextDirection.h" | 57 #include "third_party/WebKit/WebKit/chromium/public/WebTextDirection.h" |
| 57 #include "third_party/WebKit/WebKit/chromium/public/WebView.h" | 58 #include "third_party/WebKit/WebKit/chromium/public/WebView.h" |
| 58 #include "third_party/WebKit/WebKit/chromium/public/WebViewClient.h" | 59 #include "third_party/WebKit/WebKit/chromium/public/WebViewClient.h" |
| 59 #include "third_party/WebKit/WebKit/chromium/public/WebNavigationType.h" | 60 #include "third_party/WebKit/WebKit/chromium/public/WebNavigationType.h" |
| 60 #include "webkit/glue/form_data.h" | 61 #include "webkit/glue/form_data.h" |
| 61 #include "webkit/glue/image_resource_fetcher.h" | 62 #include "webkit/glue/image_resource_fetcher.h" |
| 62 #include "webkit/glue/password_form_dom_manager.h" | 63 #include "webkit/glue/password_form_dom_manager.h" |
| 63 #include "webkit/glue/plugins/webplugin_page_delegate.h" | 64 #include "webkit/glue/plugins/webplugin_page_delegate.h" |
| 64 #include "webkit/glue/webaccessibility.h" | 65 #include "webkit/glue/webaccessibility.h" |
| 65 #include "webkit/glue/webpreferences.h" | 66 #include "webkit/glue/webpreferences.h" |
| (...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 265 // Notification that the default plugin has done something about a missing | 266 // Notification that the default plugin has done something about a missing |
| 266 // plugin. See default_plugin_shared.h for possible values of |status|. | 267 // plugin. See default_plugin_shared.h for possible values of |status|. |
| 267 void OnMissingPluginStatus(WebPluginDelegateProxy* delegate, | 268 void OnMissingPluginStatus(WebPluginDelegateProxy* delegate, |
| 268 int status); | 269 int status); |
| 269 | 270 |
| 270 // Notification that the given pepper plugin we created is being deleted the | 271 // Notification that the given pepper plugin we created is being deleted the |
| 271 // pointer must not be dereferenced as this is called from the destructor of | 272 // pointer must not be dereferenced as this is called from the destructor of |
| 272 // the plugin. | 273 // the plugin. |
| 273 void OnPepperPluginDestroy(WebPluginDelegatePepper* pepper_plugin); | 274 void OnPepperPluginDestroy(WebPluginDelegatePepper* pepper_plugin); |
| 274 | 275 |
| 276 // Create a new plugin without checking the content settings. |
| 277 WebKit::WebPlugin* CreatePluginInternal( |
| 278 WebKit::WebFrame* frame, |
| 279 const WebKit::WebPluginParams& params); |
| 280 |
| 275 // Asks the browser for the CPBrowsingContext associated with this renderer. | 281 // Asks the browser for the CPBrowsingContext associated with this renderer. |
| 276 // This is an opaque identifier associated with the renderer for sending | 282 // This is an opaque identifier associated with the renderer for sending |
| 277 // messages for the given "Chrome Plugin." The Chrome Plugin API is used | 283 // messages for the given "Chrome Plugin." The Chrome Plugin API is used |
| 278 // only by gears and this function can be deleted when we remove gears. | 284 // only by gears and this function can be deleted when we remove gears. |
| 279 uint32 GetCPBrowsingContext(); | 285 uint32 GetCPBrowsingContext(); |
| 280 | 286 |
| 281 #if defined(OS_MACOSX) | 287 #if defined(OS_MACOSX) |
| 282 // Helper routines for GPU plugin support. Used by the | 288 // Helper routines for GPU plugin support. Used by the |
| 283 // WebPluginDelegateProxy, which has a pointer to the RenderView. | 289 // WebPluginDelegateProxy, which has a pointer to the RenderView. |
| 284 gfx::PluginWindowHandle AllocateFakePluginWindowHandle(bool opaque); | 290 gfx::PluginWindowHandle AllocateFakePluginWindowHandle(bool opaque); |
| (...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 421 WebKit::WebFrame* frame, const WebKit::WebURL& url, | 427 WebKit::WebFrame* frame, const WebKit::WebURL& url, |
| 422 const WebKit::WebString& name, unsigned long long documentId); | 428 const WebKit::WebString& name, unsigned long long documentId); |
| 423 virtual WebKit::WebMediaPlayer* createMediaPlayer( | 429 virtual WebKit::WebMediaPlayer* createMediaPlayer( |
| 424 WebKit::WebFrame* frame, | 430 WebKit::WebFrame* frame, |
| 425 WebKit::WebMediaPlayerClient* client); | 431 WebKit::WebMediaPlayerClient* client); |
| 426 virtual WebKit::WebApplicationCacheHost* createApplicationCacheHost( | 432 virtual WebKit::WebApplicationCacheHost* createApplicationCacheHost( |
| 427 WebKit::WebFrame* frame, | 433 WebKit::WebFrame* frame, |
| 428 WebKit::WebApplicationCacheHostClient* client); | 434 WebKit::WebApplicationCacheHostClient* client); |
| 429 virtual WebKit::WebCookieJar* cookieJar(); | 435 virtual WebKit::WebCookieJar* cookieJar(); |
| 430 virtual void willClose(WebKit::WebFrame* frame); | 436 virtual void willClose(WebKit::WebFrame* frame); |
| 431 virtual bool allowPlugins(WebKit::WebFrame* frame, bool enabled_per_settings); | |
| 432 virtual bool allowImages(WebKit::WebFrame* frame, bool enabled_per_settings); | 437 virtual bool allowImages(WebKit::WebFrame* frame, bool enabled_per_settings); |
| 433 virtual void loadURLExternally(WebKit::WebFrame* frame, | 438 virtual void loadURLExternally(WebKit::WebFrame* frame, |
| 434 const WebKit::WebURLRequest& request, | 439 const WebKit::WebURLRequest& request, |
| 435 WebKit::WebNavigationPolicy policy); | 440 WebKit::WebNavigationPolicy policy); |
| 436 virtual WebKit::WebNavigationPolicy decidePolicyForNavigation( | 441 virtual WebKit::WebNavigationPolicy decidePolicyForNavigation( |
| 437 WebKit::WebFrame* frame, | 442 WebKit::WebFrame* frame, |
| 438 const WebKit::WebURLRequest& request, | 443 const WebKit::WebURLRequest& request, |
| 439 WebKit::WebNavigationType type, | 444 WebKit::WebNavigationType type, |
| 440 const WebKit::WebNode&, | 445 const WebKit::WebNode&, |
| 441 WebKit::WebNavigationPolicy default_policy, | 446 WebKit::WebNavigationPolicy default_policy, |
| (...skipping 404 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 846 // by preferred_size_change_timer_. | 851 // by preferred_size_change_timer_. |
| 847 void CheckPreferredSize(); | 852 void CheckPreferredSize(); |
| 848 | 853 |
| 849 // Resets the |content_blocked_| array. | 854 // Resets the |content_blocked_| array. |
| 850 void ClearBlockedContentSettings(); | 855 void ClearBlockedContentSettings(); |
| 851 | 856 |
| 852 // Creates DevToolsClient and sets up JavaScript bindings for developer tools | 857 // Creates DevToolsClient and sets up JavaScript bindings for developer tools |
| 853 // UI that is going to be hosted by this RenderView. | 858 // UI that is going to be hosted by this RenderView. |
| 854 void CreateDevToolsClient(); | 859 void CreateDevToolsClient(); |
| 855 | 860 |
| 861 // Create a new placeholder for a blocked plugin. |
| 862 WebKit::WebPlugin* CreatePluginPlaceholder( |
| 863 WebKit::WebFrame* frame, |
| 864 const WebKit::WebPluginParams& params); |
| 865 |
| 856 // Sends an IPC notification that the specified content type was blocked. | 866 // Sends an IPC notification that the specified content type was blocked. |
| 857 void DidBlockContentType(ContentSettingsType settings_type); | 867 void DidBlockContentType(ContentSettingsType settings_type); |
| 858 | 868 |
| 859 // This callback is triggered when DownloadImage completes, either | 869 // This callback is triggered when DownloadImage completes, either |
| 860 // succesfully or with a failure. See DownloadImage for more details. | 870 // succesfully or with a failure. See DownloadImage for more details. |
| 861 void DidDownloadImage(webkit_glue::ImageResourceFetcher* fetcher, | 871 void DidDownloadImage(webkit_glue::ImageResourceFetcher* fetcher, |
| 862 const SkBitmap& image); | 872 const SkBitmap& image); |
| 863 | 873 |
| 864 // Requests to download an image. When done, the RenderView is | 874 // Requests to download an image. When done, the RenderView is |
| 865 // notified by way of DidDownloadImage. Returns true if the request was | 875 // notified by way of DidDownloadImage. Returns true if the request was |
| (...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1296 // ADDING NEW DATA? Please see if it fits appropriately in one of the above | 1306 // ADDING NEW DATA? Please see if it fits appropriately in one of the above |
| 1297 // sections rather than throwing it randomly at the end. If you're adding a | 1307 // sections rather than throwing it randomly at the end. If you're adding a |
| 1298 // bunch of stuff, you should probably create a helper class and put your | 1308 // bunch of stuff, you should probably create a helper class and put your |
| 1299 // data and methods on that to avoid bloating RenderView more. | 1309 // data and methods on that to avoid bloating RenderView more. |
| 1300 // --------------------------------------------------------------------------- | 1310 // --------------------------------------------------------------------------- |
| 1301 | 1311 |
| 1302 DISALLOW_COPY_AND_ASSIGN(RenderView); | 1312 DISALLOW_COPY_AND_ASSIGN(RenderView); |
| 1303 }; | 1313 }; |
| 1304 | 1314 |
| 1305 #endif // CHROME_RENDERER_RENDER_VIEW_H_ | 1315 #endif // CHROME_RENDERER_RENDER_VIEW_H_ |
| OLD | NEW |