summaryrefslogtreecommitdiffstats
path: root/content/shell
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-14 21:11:57 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-14 21:11:57 +0000
commit38b098f226b6b64fcdebcd16100bfe45fad0e57e (patch)
tree6fb5e5c84ae151149c9c3a09943c2eb745b13b37 /content/shell
parent85d43f0ef0787ec7b076d11648ec30da0dd37f7f (diff)
downloadchromium_src-38b098f226b6b64fcdebcd16100bfe45fad0e57e.zip
chromium_src-38b098f226b6b64fcdebcd16100bfe45fad0e57e.tar.gz
chromium_src-38b098f226b6b64fcdebcd16100bfe45fad0e57e.tar.bz2
Move creation of content TabContentsViews to content so that we can hide these headers through DEPS and avoid any more includes until TabContentsViewsViews is removed. I also moved all the TCVXDelegate to be in one header, that way we can more conveniently ask the embedder for a delegate without a lot of ifdefs.
BUG=98716 Review URL: https://chromiumcodereview.appspot.com/9700023 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@126730 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/shell')
-rw-r--r--content/shell/shell_content_browser_client.cc14
-rw-r--r--content/shell/shell_content_browser_client.h4
2 files changed, 8 insertions, 10 deletions
diff --git a/content/shell/shell_content_browser_client.cc b/content/shell/shell_content_browser_client.cc
index c0c1365..686e6ce 100644
--- a/content/shell/shell_content_browser_client.cc
+++ b/content/shell/shell_content_browser_client.cc
@@ -38,22 +38,18 @@ BrowserMainParts* ShellContentBrowserClient::CreateBrowserMainParts(
return new ShellBrowserMainParts(parameters);
}
-WebContentsView* ShellContentBrowserClient::CreateWebContentsView(
+WebContentsView* ShellContentBrowserClient::OverrideCreateWebContentsView(
WebContents* web_contents) {
ShellDevToolsDelegate* devtools_delegate =
shell_browser_main_parts_->devtools_delegate();
if (devtools_delegate)
devtools_delegate->AddWebContents(web_contents);
+ return NULL;
+}
-#if defined(OS_WIN)
- return new TabContentsViewWin(web_contents, NULL);
-#elif defined(OS_LINUX)
- return new TabContentsViewGtk(web_contents, NULL);
-#elif defined(OS_MACOSX)
- return web_contents_view_mac::CreateWebContentsView(web_contents, NULL);
-#else
+WebContentsViewDelegate* ShellContentBrowserClient::GetWebContentsViewDelegate(
+ content::WebContents* web_contents) {
return NULL;
-#endif
}
void ShellContentBrowserClient::RenderViewHostCreated(
diff --git a/content/shell/shell_content_browser_client.h b/content/shell/shell_content_browser_client.h
index 5db7a3b..a7322ab 100644
--- a/content/shell/shell_content_browser_client.h
+++ b/content/shell/shell_content_browser_client.h
@@ -27,7 +27,9 @@ class ShellContentBrowserClient : public ContentBrowserClient {
virtual BrowserMainParts* CreateBrowserMainParts(
const content::MainFunctionParams& parameters) OVERRIDE;
- virtual WebContentsView* CreateWebContentsView(
+ virtual WebContentsView* OverrideCreateWebContentsView(
+ WebContents* web_contents) OVERRIDE;
+ virtual WebContentsViewDelegate* GetWebContentsViewDelegate(
WebContents* web_contents) OVERRIDE;
virtual void RenderViewHostCreated(
RenderViewHost* render_view_host) OVERRIDE;