summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormhm@chromium.org <mhm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-03 17:14:56 +0000
committermhm@chromium.org <mhm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-03 17:14:56 +0000
commit9ab86d92329333998be78bb3f1cebad74cc92f7e (patch)
tree5a5dd7bfef8da5a7f9dfebd6845938c5ed210637
parentd01f6dc88826e24f25888f30fd8d724f546aecf8 (diff)
downloadchromium_src-9ab86d92329333998be78bb3f1cebad74cc92f7e.zip
chromium_src-9ab86d92329333998be78bb3f1cebad74cc92f7e.tar.gz
chromium_src-9ab86d92329333998be78bb3f1cebad74cc92f7e.tar.bz2
Allow cancellable download items to be removable from download shelf.
BUG=18235 (http://crbug.com/18235) TEST=Cancel a big download and remove it. Review URL: http://codereview.chromium.org/159769 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@22276 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/download/download_shelf.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/chrome/browser/download/download_shelf.cc b/chrome/browser/download/download_shelf.cc
index 2be924f..b4d7701 100644
--- a/chrome/browser/download/download_shelf.cc
+++ b/chrome/browser/download/download_shelf.cc
@@ -73,7 +73,8 @@ bool DownloadShelfContextMenu::IsItemCommandEnabled(int id) const {
case CANCEL:
return download_->state() == DownloadItem::IN_PROGRESS;
case REMOVE_ITEM:
- return download_->state() == DownloadItem::COMPLETE;
+ return download_->state() == DownloadItem::COMPLETE ||
+ download_->state() == DownloadItem::CANCELLED;
default:
return id > 0 && id < MENU_LAST;
}