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

Unified Diff: content/shell/shell_browser_context.cc

Issue 10867060: Move some download tests to content from chrome. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Shifted over to using a psuedo-binary file. Created 8 years, 4 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
Index: content/shell/shell_browser_context.cc
diff --git a/content/shell/shell_browser_context.cc b/content/shell/shell_browser_context.cc
index d1ecd3e31ac6622d22df19f81a31a9ba814fad7a..b0da3ae42189825e79fc1aa9cfbefabc5eeec6f3 100644
--- a/content/shell/shell_browser_context.cc
+++ b/content/shell/shell_browser_context.cc
@@ -85,8 +85,10 @@ bool ShellBrowserContext::IsOffTheRecord() const {
DownloadManagerDelegate* ShellBrowserContext::GetDownloadManagerDelegate() {
DownloadManager* manager = BrowserContext::GetDownloadManager(this);
- download_manager_delegate_ = new ShellDownloadManagerDelegate();
- download_manager_delegate_->SetDownloadManager(manager);
+ if (!download_manager_delegate_.get()) {
+ download_manager_delegate_ = new ShellDownloadManagerDelegate();
+ download_manager_delegate_->SetDownloadManager(manager);
+ }
return download_manager_delegate_.get();
}

Powered by Google App Engine
This is Rietveld 408576698