diff options
author | jcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-25 22:27:41 +0000 |
---|---|---|
committer | jcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-25 22:27:41 +0000 |
commit | 7f2855f8e27cca78479481d80a06618568c8d10a (patch) | |
tree | 21ccd397787afa9c1f33bb4141a23b56b01c789f /chrome/browser/tab_contents.h | |
parent | 7e2639413fc87b91d1327a57303493d84823f070 (diff) | |
download | chromium_src-7f2855f8e27cca78479481d80a06618568c8d10a.zip chromium_src-7f2855f8e27cca78479481d80a06618568c8d10a.tar.gz chromium_src-7f2855f8e27cca78479481d80a06618568c8d10a.tar.bz2 |
Some crashes reported from the field seems to indicate that when
storing/restoring the focused view on a tab, the focus manager or focused view
is garbage.
I have not been able to repro any of these crashers and was not able to discover
much from the mini-dumps.
This is a simple work-around that just prevents the storing/restoring of focus
when closing a tab, to avoid the cases reported in the crasher.
Note this is the equivalent of CL 12622 (which is on the release branck), which was reviewed by Ben.
BUG=4633
Review URL: http://codereview.chromium.org/12652
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@6000 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/tab_contents.h')
-rw-r--r-- | chrome/browser/tab_contents.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/chrome/browser/tab_contents.h b/chrome/browser/tab_contents.h index 2f78a79..dad5f63 100644 --- a/chrome/browser/tab_contents.h +++ b/chrome/browser/tab_contents.h @@ -246,6 +246,11 @@ class TabContents : public PageNavigator, bool is_active() const { return is_active_; } void set_is_active(bool active) { is_active_ = active; } + // Whether the tab is in the process of being destroyed. + // Added as a tentative work-around for focus related bug #4633. This allows + // us not to store focus when a tab is being closed. + bool is_being_destroyed() const { return is_being_destroyed_; } + // Convenience method for notifying the delegate of a navigation state // change. See TabContentsDelegate. void NotifyNavigationStateChanged(unsigned changed_flags); @@ -542,6 +547,9 @@ class TabContents : public PageNavigator, // Delegates for InfoBars associated with this TabContents. std::vector<InfoBarDelegate*> infobar_delegates_; + // See getter above. + bool is_being_destroyed_; + DISALLOW_COPY_AND_ASSIGN(TabContents); }; |