diff options
author | estade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-06 05:16:50 +0000 |
---|---|---|
committer | estade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-06 05:16:50 +0000 |
commit | c9cd22294bf1ef854e41c547d7c9f722b13593f6 (patch) | |
tree | f6fa6d01d068631718ef36f32470a22386bc6cec /chrome/browser/browser.cc | |
parent | 2ac844349bbe511cf17e597bfc3e8a0aaab9ceab (diff) | |
download | chromium_src-c9cd22294bf1ef854e41c547d7c9f722b13593f6.zip chromium_src-c9cd22294bf1ef854e41c547d7c9f722b13593f6.tar.gz chromium_src-c9cd22294bf1ef854e41c547d7c9f722b13593f6.tar.bz2 |
Merge two TabContents::InvalidateTypes types and properly update tab download icon.
INVALIDATE_FAVICON and INVALIDATE_TITLE become INVALIDATE_TAB. Also removed some dead code.
TEST=starting a download in a tab should show the download icon. Closing the dshelf should make the icon disappear.
Review URL: http://codereview.chromium.org/109050
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15387 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser.cc')
-rw-r--r-- | chrome/browser/browser.cc | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/chrome/browser/browser.cc b/chrome/browser/browser.cc index efee083..c2e3bf8 100644 --- a/chrome/browser/browser.cc +++ b/chrome/browser/browser.cc @@ -1918,12 +1918,6 @@ void Browser::ConvertContentsToApplication(TabContents* contents) { browser->window()->Show(); } -void Browser::ContentsStateChanged(TabContents* source) { - int index = tabstrip_model_.GetIndexOfTabContents(source); - if (index != TabStripModel::kNoTab) - tabstrip_model_.UpdateTabContentsStateAt(index, true); -} - bool Browser::ShouldDisplayURLField() { return !IsApplication(); } @@ -2338,18 +2332,6 @@ void Browser::ProcessPendingUIUpdates() { updated_stuff[contents] = flags; } - // Updates to the title or favicon require a tab repaint. However, the - // inverse is not true since updates to the title also update the window - // title. - bool invalidate_tab = false; - if (flags & TabContents::INVALIDATE_TITLE || - flags & TabContents::INVALIDATE_FAVICON) { - invalidate_tab = true; - - // Anything that repaints the tab means the favicon is updated. - updated_stuff[contents] |= TabContents::INVALIDATE_FAVICON; - } - if (flags & TabContents::INVALIDATE_PAGE_ACTIONS) window()->GetLocationBar()->UpdatePageActions(); @@ -2358,7 +2340,7 @@ void Browser::ProcessPendingUIUpdates() { if (flags & TabContents::INVALIDATE_LOAD && GetStatusBubble()) GetStatusBubble()->SetStatus(GetSelectedTabContents()->GetStatusText()); - if (invalidate_tab) { // INVALIDATE_TITLE or INVALIDATE_FAVICON. + if (flags & TabContents::INVALIDATE_TAB) { tabstrip_model_.UpdateTabContentsStateAt( tabstrip_model_.GetIndexOfController(&contents->controller()), false); window_->UpdateTitleBar(); |