diff options
author | jcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-26 00:38:13 +0000 |
---|---|---|
committer | jcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-26 00:38:13 +0000 |
commit | cd7f69091a1579815606d9b8b51e3de0e34e0596 (patch) | |
tree | a0fc71658010090143f4abd49cf95fa9483cb8d3 /chrome/browser/views | |
parent | 24fd0b7823a8e47bf9f7df8290bb68a8f3adf79d (diff) | |
download | chromium_src-cd7f69091a1579815606d9b8b51e3de0e34e0596.zip chromium_src-cd7f69091a1579815606d9b8b51e3de0e34e0596.tar.gz chromium_src-cd7f69091a1579815606d9b8b51e3de0e34e0596.tar.bz2 |
Reverting my previous commit, it seems to be breaking the UI tests in debug mode.
Review URL: http://codereview.chromium.org/12666
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@6020 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/views')
-rw-r--r-- | chrome/browser/views/frame/browser_view.cc | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/chrome/browser/views/frame/browser_view.cc b/chrome/browser/views/frame/browser_view.cc index 019fdc8..91b148c 100644 --- a/chrome/browser/views/frame/browser_view.cc +++ b/chrome/browser/views/frame/browser_view.cc @@ -647,10 +647,7 @@ void BrowserView::TabSelectedAt(TabContents* old_contents, bool user_gesture) { DCHECK(old_contents != new_contents); - // We do not store the focus when closing the tab to work-around bug 4633. - // Some reports seem to show that the focus manager and/or focused view can - // be garbage at that point, it is not clear why. - if (old_contents && !old_contents->is_being_destroyed()) + if (old_contents) old_contents->StoreFocus(); // Update various elements that are interested in knowing the current @@ -662,10 +659,8 @@ void BrowserView::TabSelectedAt(TabContents* old_contents, // required to make features like Duplicate Tab, Undo Close Tab, // etc not result in sad tab. new_contents->DidBecomeSelected(); - if (BrowserList::GetLastActive() == browser_ && - !browser_->tabstrip_model()->closing_all()) { + if (BrowserList::GetLastActive() == browser_) new_contents->RestoreFocus(); - } // Update all the UI bits. UpdateTitleBar(); |