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

Unified Diff: chrome/browser/ui/cocoa/dev_tools_controller.mm

Issue 9015022: Replace most of Browser::GetSelectedTabContents calls into Browser::GetSelectedWebContents. I've ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 8 years, 12 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/cocoa/dev_tools_controller.mm
===================================================================
--- chrome/browser/ui/cocoa/dev_tools_controller.mm (revision 116109)
+++ chrome/browser/ui/cocoa/dev_tools_controller.mm (working copy)
@@ -17,6 +17,8 @@
#include "chrome/common/pref_names.h"
#include "content/browser/tab_contents/tab_contents.h"
+using content::WebContents;
+
namespace {
// Minimal height of devtools pane or content pane when devtools are docked
@@ -29,7 +31,7 @@
@interface DevToolsController (Private)
-- (void)showDevToolsContents:(TabContents*)devToolsContents
+- (void)showDevToolsContents:(WebContents*)devToolsContents
withProfile:(Profile*)profile;
- (void)showDevToolsContainer:(Profile*)profile;
- (void)hideDevToolsContainer:(Profile*)profile;
@@ -69,13 +71,13 @@
return splitView_.get();
}
-- (void)updateDevToolsForTabContents:(TabContents*)contents
+- (void)updateDevToolsForWebContents:(WebContents*)contents
withProfile:(Profile*)profile {
// Get current devtools content.
TabContentsWrapper* devToolsTab = contents ?
DevToolsWindow::GetDevToolsContents(contents) : NULL;
- TabContents* devToolsContents = devToolsTab ?
- devToolsTab->tab_contents() : NULL;
+ WebContents* devToolsContents = devToolsTab ?
+ devToolsTab->web_contents() : NULL;
[self showDevToolsContents:devToolsContents withProfile:profile];
}
@@ -99,7 +101,7 @@
[contentsController_ ensureContentsVisible];
}
-- (void)showDevToolsContents:(TabContents*)devToolsContents
+- (void)showDevToolsContents:(WebContents*)devToolsContents
withProfile:(Profile*)profile {
[contentsController_ ensureContentsSizeDoesNotChange];
@@ -117,7 +119,8 @@
}
}
- [contentsController_ changeTabContents:devToolsContents];
+ [contentsController_ changeTabContents:
+ static_cast<TabContents*>(devToolsContents)];
}
- (void)showDevToolsContainer:(Profile*)profile {
« no previous file with comments | « chrome/browser/ui/cocoa/dev_tools_controller.h ('k') | chrome/browser/ui/cocoa/extensions/extension_action_context_menu.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698