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

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

Issue 55046: Installing extensions (drag/drop, download crx file) will now be... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 8 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/dom_ui/downloads_ui.cc ('k') | chrome/browser/download/download_file.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 // Objects that handle file operations for downloads, on the download thread. 5 // Objects that handle file operations for downloads, on the download thread.
6 // 6 //
7 // The DownloadFileManager owns a set of DownloadFile objects, each of which 7 // The DownloadFileManager owns a set of DownloadFile objects, each of which
8 // represent one in progress download and performs the disk IO for that 8 // represent one in progress download and performs the disk IO for that
9 // download. The DownloadFileManager itself is a singleton object owned by the 9 // download. The DownloadFileManager itself is a singleton object owned by the
10 // ResourceDispatcherHost. 10 // ResourceDispatcherHost.
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
198 198
199 // Handler for shell operations sent from the UI to the download thread. 199 // Handler for shell operations sent from the UI to the download thread.
200 void OnShowDownloadInShell(const FilePath& full_path); 200 void OnShowDownloadInShell(const FilePath& full_path);
201 // Handler to open or execute a downloaded file. 201 // Handler to open or execute a downloaded file.
202 void OnOpenDownloadInShell(const FilePath& full_path, 202 void OnOpenDownloadInShell(const FilePath& full_path,
203 const GURL& url, 203 const GURL& url,
204 gfx::NativeView parent_window); 204 gfx::NativeView parent_window);
205 205
206 // The download manager has provided a final name for a download. Sent from 206 // The download manager has provided a final name for a download. Sent from
207 // the UI thread and run on the download thread. 207 // the UI thread and run on the download thread.
208 void OnFinalDownloadName(int id, const FilePath& full_path); 208 void OnFinalDownloadName(int id, const FilePath& full_path,
209 DownloadManager* download_manager);
209 210
210 // Timer notifications. 211 // Timer notifications.
211 void UpdateInProgressDownloads(); 212 void UpdateInProgressDownloads();
212 213
213 MessageLoop* file_loop() const { return file_loop_; } 214 MessageLoop* file_loop() const { return file_loop_; }
214 215
215 // Called by the download manager to delete non validated dangerous downloads. 216 // Called by the download manager to delete non validated dangerous downloads.
216 static void DeleteFile(const FilePath& path); 217 static void DeleteFile(const FilePath& path);
217 218
218 private: 219 private:
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
269 // Used for progress updates on the UI thread, mapping download->id() to bytes 270 // Used for progress updates on the UI thread, mapping download->id() to bytes
270 // received so far. Written to by the file thread and read by the UI thread. 271 // received so far. Written to by the file thread and read by the UI thread.
271 typedef base::hash_map<int, int64> ProgressMap; 272 typedef base::hash_map<int, int64> ProgressMap;
272 ProgressMap ui_progress_; 273 ProgressMap ui_progress_;
273 Lock progress_lock_; 274 Lock progress_lock_;
274 275
275 DISALLOW_COPY_AND_ASSIGN(DownloadFileManager); 276 DISALLOW_COPY_AND_ASSIGN(DownloadFileManager);
276 }; 277 };
277 278
278 #endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_FILE_H_ 279 #endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_FILE_H_
OLDNEW
« no previous file with comments | « chrome/browser/dom_ui/downloads_ui.cc ('k') | chrome/browser/download/download_file.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698