Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(596)

Unified Diff: chrome/browser/download/download_hidden.cc

Issue 10260018: Test downloads.download() disallows unsafe headers (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: DownloadHidden Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/download/download_hidden.h ('k') | chrome/browser/ui/webui/downloads_dom_handler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/download/download_hidden.cc
diff --git a/chrome/browser/download/download_hidden.cc b/chrome/browser/download/download_hidden.cc
new file mode 100644
index 0000000000000000000000000000000000000000..e48c326bbacdddb831d5b53f5febbe19f5de42f2
--- /dev/null
+++ b/chrome/browser/download/download_hidden.cc
@@ -0,0 +1,20 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "chrome/browser/download/download_hidden.h"
+
+namespace {
+static const char kKey[] = "DownloadItem DownloadHidden";
+}
+
+bool DownloadHidden::Get(content::DownloadItem* download_item) {
+ return download_item->GetExternalData(kKey) != NULL;
+}
+
+DownloadHidden::DownloadHidden(content::DownloadItem* download_item) {
+ download_item->SetExternalData(kKey, this);
+}
+
+DownloadHidden::~DownloadHidden() {
+}
« no previous file with comments | « chrome/browser/download/download_hidden.h ('k') | chrome/browser/ui/webui/downloads_dom_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698