Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(125)

Side by Side Diff: content/renderer/content_renderer_client.h

Issue 6765011: Move the dispatching of extension messages out of RenderThread. This also moves a bunch of exten... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/test/render_view_test.cc ('k') | content/renderer/content_renderer_client.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_CONTENT_RENDERER_CLIENT_H_ 5 #ifndef CONTENT_RENDERER_CONTENT_RENDERER_CLIENT_H_
6 #define CONTENT_RENDERER_CONTENT_RENDERER_CLIENT_H_ 6 #define CONTENT_RENDERER_CONTENT_RENDERER_CLIENT_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
11 #include "base/string16.h" 11 #include "base/string16.h"
12 #include "content/common/content_client.h" 12 #include "content/common/content_client.h"
13 13
14 class GURL;
14 class RenderView; 15 class RenderView;
15 class SkBitmap; 16 class SkBitmap;
16 17
17 namespace WebKit { 18 namespace WebKit {
18 class WebFrame; 19 class WebFrame;
19 class WebPlugin; 20 class WebPlugin;
20 class WebURLRequest; 21 class WebURLRequest;
21 struct WebPluginParams; 22 struct WebPluginParams;
22 struct WebURLError; 23 struct WebURLError;
23 } 24 }
24 25
25 namespace content { 26 namespace content {
26 27
27 // Embedder API for participating in renderer logic. 28 // Embedder API for participating in renderer logic.
28 class ContentRendererClient { 29 class ContentRendererClient {
29 public: 30 public:
30 virtual SkBitmap* GetSadPluginBitmap(); 31 virtual SkBitmap* GetSadPluginBitmap();
32
31 virtual std::string GetDefaultEncoding(); 33 virtual std::string GetDefaultEncoding();
34
32 // Create a plugin in the given frame. Can return NULL, in which case 35 // Create a plugin in the given frame. Can return NULL, in which case
33 // RenderView will create a plugin itself. 36 // RenderView will create a plugin itself.
34 virtual WebKit::WebPlugin* CreatePlugin( 37 virtual WebKit::WebPlugin* CreatePlugin(
35 RenderView* render_view, 38 RenderView* render_view,
36 WebKit::WebFrame* frame, 39 WebKit::WebFrame* frame,
37 const WebKit::WebPluginParams& params); 40 const WebKit::WebPluginParams& params);
41
38 // Returns the html to display when a navigation error occurs. 42 // Returns the html to display when a navigation error occurs.
39 virtual std::string GetNavigationErrorHtml( 43 virtual std::string GetNavigationErrorHtml(
40 const WebKit::WebURLRequest& failed_request, 44 const WebKit::WebURLRequest& failed_request,
41 const WebKit::WebURLError& error); 45 const WebKit::WebURLError& error);
46
42 // Returns the ISO 639_1 language code of the specified |text|, or 'unknown' 47 // Returns the ISO 639_1 language code of the specified |text|, or 'unknown'
43 // if it failed. 48 // if it failed.
44 virtual std::string DetermineTextLanguage(const string16& text); 49 virtual std::string DetermineTextLanguage(const string16& text);
50
51 // Returns true if the renderer process should schedule the idle handler when
52 // all widgets are hidden.
53 virtual bool RunIdleHandlerWhenWidgetsHidden();
54
55 // Returns true if the given url can create popup windows.
56 virtual bool AllowPopup(const GURL& creator);
45 }; 57 };
46 58
47 } // namespace content 59 } // namespace content
48 60
49 #endif // CONTENT_RENDERER_CONTENT_RENDERER_CLIENT_H_ 61 #endif // CONTENT_RENDERER_CONTENT_RENDERER_CLIENT_H_
OLDNEW
« no previous file with comments | « chrome/test/render_view_test.cc ('k') | content/renderer/content_renderer_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698