Chromium Code Reviews| Index: content/browser/download/download_item_impl.cc |
| diff --git a/content/browser/download/download_item_impl.cc b/content/browser/download/download_item_impl.cc |
| index a3e72ffa469e50f0efd18f92c63a50c2a99e0e16..5fba3ede98ff84b9cb6ef2e7bfe91cbf7c0bf74c 100644 |
| --- a/content/browser/download/download_item_impl.cc |
| +++ b/content/browser/download/download_item_impl.cc |
| @@ -604,7 +604,6 @@ void DownloadItemImpl::SetDangerType(content::DownloadDangerType danger_type) { |
| net::NetLog::TYPE_DOWNLOAD_ITEM_SAFETY_STATE_UPDATED, |
| base::Bind(&download_net_logs::ItemCheckedCallback, |
| GetDangerType(), GetSafetyState())); |
| - UpdateObservers(); |
| } |
| } |
| @@ -871,10 +870,10 @@ void DownloadItemImpl::OnTargetPathDetermined( |
| const FilePath& target_path, |
| TargetDisposition disposition, |
| content::DownloadDangerType danger_type) { |
| - // TODO(rdsmith): Change to DCHECK after http://crbug.com/85408 resolved. |
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
| target_path_ = target_path; |
| target_disposition_ = disposition; |
| + // SetDangerType() may call UpdateObservers() again. |
|
asanka
2012/07/25 19:36:35
Stale comment?
benjhayden
2012/07/25 21:26:26
Done.
|
| SetDangerType(danger_type); |
| } |
| @@ -882,6 +881,7 @@ void DownloadItemImpl::OnTargetPathSelected(const FilePath& target_path) { |
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
| DCHECK_EQ(TARGET_DISPOSITION_PROMPT, target_disposition_); |
| target_path_ = target_path; |
| + UpdateObservers(); |
| } |
| void DownloadItemImpl::OnContentCheckCompleted( |
| @@ -890,6 +890,7 @@ void DownloadItemImpl::OnContentCheckCompleted( |
| DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
| DCHECK(AllDataSaved()); |
| SetDangerType(danger_type); |
| + UpdateObservers(); |
|
asanka
2012/07/25 19:36:35
I was under the impression that we weren't going t
benjhayden
2012/07/25 21:26:26
I am so far down the rabbit hole, I don't know any
asanka
2012/07/25 21:56:04
Whoa. Apparently I clicked on the wrong UpdateObse
benjhayden
2012/07/26 15:03:42
Thank you! That was very helpful. :-)
PTAL
|
| } |
| void DownloadItemImpl::OnIntermediatePathDetermined( |