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

Side by Side Diff: chrome/browser/download/download_file.cc

Issue 113169: Move win_util.h from common to app. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/browser_main_win.cc ('k') | chrome/browser/download/download_manager.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/download/download_file.h" 5 #include "chrome/browser/download/download_file.h"
6 6
7 #include "base/file_util.h" 7 #include "base/file_util.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "base/stl_util-inl.h" 9 #include "base/stl_util-inl.h"
10 #include "base/string_util.h" 10 #include "base/string_util.h"
11 #include "base/task.h" 11 #include "base/task.h"
12 #include "build/build_config.h" 12 #include "build/build_config.h"
13 #include "chrome/browser/browser_process.h" 13 #include "chrome/browser/browser_process.h"
14 #include "chrome/browser/download/download_manager.h" 14 #include "chrome/browser/download/download_manager.h"
15 #include "chrome/browser/profile.h" 15 #include "chrome/browser/profile.h"
16 #include "chrome/browser/renderer_host/resource_dispatcher_host.h" 16 #include "chrome/browser/renderer_host/resource_dispatcher_host.h"
17 #include "chrome/browser/tab_contents/tab_util.h" 17 #include "chrome/browser/tab_contents/tab_util.h"
18 #include "chrome/browser/tab_contents/tab_contents.h" 18 #include "chrome/browser/tab_contents/tab_contents.h"
19 #include "chrome/common/chrome_paths.h" 19 #include "chrome/common/chrome_paths.h"
20 #include "chrome/common/platform_util.h" 20 #include "chrome/common/platform_util.h"
21 #include "googleurl/src/gurl.h" 21 #include "googleurl/src/gurl.h"
22 #include "net/base/io_buffer.h" 22 #include "net/base/io_buffer.h"
23 #include "net/base/net_util.h" 23 #include "net/base/net_util.h"
24 #include "net/url_request/url_request_context.h" 24 #include "net/url_request/url_request_context.h"
25 25
26 #if defined(OS_WIN) 26 #if defined(OS_WIN)
27 #include "chrome/common/win_util.h" 27 #include "app/win_util.h"
28 #include "chrome/common/win_safe_util.h" 28 #include "chrome/common/win_safe_util.h"
29 #elif defined(OS_MACOSX) 29 #elif defined(OS_MACOSX)
30 #include "chrome/common/quarantine_mac.h" 30 #include "chrome/common/quarantine_mac.h"
31 #endif 31 #endif
32 32
33 // Throttle updates to the UI thread so that a fast moving download doesn't 33 // Throttle updates to the UI thread so that a fast moving download doesn't
34 // cause it to become unresponsive (in milliseconds). 34 // cause it to become unresponsive (in milliseconds).
35 static const int kUpdatePeriodMs = 500; 35 static const int kUpdatePeriodMs = 500;
36 36
37 // Timer task for posting UI updates. This task is created and maintained by 37 // Timer task for posting UI updates. This task is created and maintained by
(...skipping 561 matching lines...) Expand 10 before | Expand all | Expand 10 after
599 ui_loop_->PostTask(FROM_HERE, NewRunnableMethod( 599 ui_loop_->PostTask(FROM_HERE, NewRunnableMethod(
600 this, &DownloadFileManager::StopUpdateTimer)); 600 this, &DownloadFileManager::StopUpdateTimer));
601 } 601 }
602 602
603 // static 603 // static
604 void DownloadFileManager::DeleteFile(const FilePath& path) { 604 void DownloadFileManager::DeleteFile(const FilePath& path) {
605 // Make sure we only delete files. 605 // Make sure we only delete files.
606 if (!file_util::DirectoryExists(path)) 606 if (!file_util::DirectoryExists(path))
607 file_util::Delete(path, false); 607 file_util::Delete(path, false);
608 } 608 }
OLDNEW
« no previous file with comments | « chrome/browser/browser_main_win.cc ('k') | chrome/browser/download/download_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698