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

Unified Diff: chrome/browser/instant/instant_controller.cc

Issue 12334073: Remove WebContents methods that duplicate WebContentsView methods. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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/instant/instant_controller.cc
diff --git a/chrome/browser/instant/instant_controller.cc b/chrome/browser/instant/instant_controller.cc
index 86db17b4540fe6fa85b7333ed1802c7000341702..e744538d5d2f6b715bfa0e48d34fbb7b695c64c8 100644
--- a/chrome/browser/instant/instant_controller.cc
+++ b/chrome/browser/instant/instant_controller.cc
@@ -30,6 +30,7 @@
#include "content/public/browser/notification_service.h"
#include "content/public/browser/render_widget_host_view.h"
#include "content/public/browser/web_contents.h"
+#include "content/public/browser/web_contents_view.h"
#include "net/base/escape.h"
#include "third_party/icu/public/common/unicode/normalizer2.h"
@@ -140,7 +141,7 @@ bool IsViewInContents(gfx::NativeView view, content::WebContents* contents) {
if (!view || !rwhv)
return false;
- gfx::NativeView tab_view = contents->GetNativeView();
+ gfx::NativeView tab_view = contents->GetView()->GetNativeView();
if (view == rwhv->GetNativeView() || view == tab_view)
return true;
@@ -581,7 +582,7 @@ bool InstantController::CommitIfPossible(InstantCommitType type) {
last_suggestion_.behavior == INSTANT_COMPLETE_NEVER)) {
EnsureSearchTermsAreSet(instant_tab_->contents(), last_omnibox_text_);
instant_tab_->Submit(last_omnibox_text_);
- instant_tab_->contents()->Focus();
+ instant_tab_->contents()->GetView()->Focus();
return true;
}
return false;
@@ -1101,7 +1102,7 @@ void InstantController::StopCapturingKeyStrokes(
return;
DCHECK(IsContentsFrom(instant_tab(), contents));
- contents->Focus();
+ contents->GetView()->Focus();
}
void InstantController::NavigateToURL(const content::WebContents* contents,

Powered by Google App Engine
This is Rietveld 408576698