summaryrefslogtreecommitdiffstats
path: root/ui
diff options
context:
space:
mode:
authordmazzoni@chromium.org <dmazzoni@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-23 19:23:48 +0000
committerdmazzoni@chromium.org <dmazzoni@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-23 19:23:48 +0000
commit5a322ae6549fe1bec02167c68003c1e1538ce717 (patch)
treee193b9ba93738eb1b0bd926012b07e070aebce83 /ui
parent4a0ae6fde4030129a30d861e69f679f924a7df02 (diff)
downloadchromium_src-5a322ae6549fe1bec02167c68003c1e1538ce717.zip
chromium_src-5a322ae6549fe1bec02167c68003c1e1538ce717.tar.gz
chromium_src-5a322ae6549fe1bec02167c68003c1e1538ce717.tar.bz2
Revert 133490 - Make sure the WebContents has focus after being attached to a WebView, if that WebView was focused.
Reverting because PrintPreviewUIUnitTest.PrintPreviewData failed on Chrome OS, with a stack trace including views::WebView::AttachWebContents(). http://crbug.com/123995 TEST=none. I need to add a set of unit tests to views for WebView, but that requires creating a new exe that can depend on content. I've filed http://crbug.com/124662 for this. Review URL: https://chromiumcodereview.appspot.com/10186007 TBR=ben@chromium.org Review URL: https://chromiumcodereview.appspot.com/10181007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@133491 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui')
-rw-r--r--ui/views/controls/webview/webview.cc6
1 files changed, 0 insertions, 6 deletions
diff --git a/ui/views/controls/webview/webview.cc b/ui/views/controls/webview/webview.cc
index af7803b..ad5fc8a 100644
--- a/ui/views/controls/webview/webview.cc
+++ b/ui/views/controls/webview/webview.cc
@@ -180,12 +180,6 @@ void WebView::AttachWebContents() {
if (web_contents_) {
wcv_holder_->Attach(web_contents_->GetNativeView());
- // The WebContentsView will not be focused automatically when it is
- // attached, so we need to pass on focus to it if the FocusManager thinks
- // the WebView is focused.
- if (GetFocusManager()->GetFocusedView() == this)
- web_contents_->Focus();
-
registrar_.Add(
this,
content::NOTIFICATION_RENDER_VIEW_HOST_CHANGED,