diff options
author | avi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-10-08 14:06:21 +0000 |
---|---|---|
committer | avi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-10-08 14:06:21 +0000 |
commit | 351e823dc7bab899d9f1293c2e657346fd39d3d6 (patch) | |
tree | 018319794de2bfc59c9fc6b115415fed19656b77 /chrome/browser/cocoa | |
parent | 4bf6afd4a6c3c6c506a2b846b4ebf0c2c3f27805 (diff) | |
download | chromium_src-351e823dc7bab899d9f1293c2e657346fd39d3d6.zip chromium_src-351e823dc7bab899d9f1293c2e657346fd39d3d6.tar.gz chromium_src-351e823dc7bab899d9f1293c2e657346fd39d3d6.tar.bz2 |
Remove auto-open files from the download shelf on auto-open. This is the Mac version of r20787.
BUG=http://crbug.com/18719
TEST=download a theme, make sure that it doesn't stay in the download shelf.
Review URL: http://codereview.chromium.org/268008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28391 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/cocoa')
-rw-r--r-- | chrome/browser/cocoa/download_item_mac.mm | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/chrome/browser/cocoa/download_item_mac.mm b/chrome/browser/cocoa/download_item_mac.mm index e025d06..ecf7f08 100644 --- a/chrome/browser/cocoa/download_item_mac.mm +++ b/chrome/browser/cocoa/download_item_mac.mm @@ -46,6 +46,10 @@ void DownloadItemMac::OnDownloadUpdated(DownloadItem* download) { case DownloadItem::IN_PROGRESS: case DownloadItem::CANCELLED: case DownloadItem::COMPLETE: + if (download->auto_opened()) { + [item_controller_ remove]; // We're deleted now! + return; + } [item_controller_ setStateFromDownload:download_model_.get()]; break; default: |