From 476f21a7c670f892550497f5701fbc3af2fac577 Mon Sep 17 00:00:00 2001 From: "arv@google.com" Date: Wed, 27 May 2009 00:58:31 +0000 Subject: Use the original profile for the downloads manager so that a download manager in an incognito window is in sync with all other download managers. BUG=11514 TEST=Open a download manager (Ctrl+J) and an incognito window with a download manager (Ctrl+Shift+N followed by Ctrl+J). Then start to download a file and note that both download managers should get updated. Try pausing and eventually click "Remove all" in either DM and all downloads should get removed from both DMs. Review URL: http://codereview.chromium.org/115804 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16960 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/dom_ui/downloads_ui.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/chrome/browser/dom_ui/downloads_ui.cc b/chrome/browser/dom_ui/downloads_ui.cc index 9039200..6840b00 100644 --- a/chrome/browser/dom_ui/downloads_ui.cc +++ b/chrome/browser/dom_ui/downloads_ui.cc @@ -118,7 +118,8 @@ void DownloadsUIHTMLSource::StartDataRequest(const std::string& path, /////////////////////////////////////////////////////////////////////////////// DownloadsUI::DownloadsUI(TabContents* contents) : DOMUI(contents) { - DownloadManager* dlm = GetProfile()->GetDownloadManager(); + DownloadManager* dlm = GetProfile()->GetOriginalProfile()-> + GetDownloadManager(); DownloadsDOMHandler* handler = new DownloadsDOMHandler(this, dlm); AddMessageHandler(handler); -- cgit v1.1