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

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

Issue 5606002: Move:... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years 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
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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_history.h" 5 #include "chrome/browser/download/download_history.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "chrome/browser/history/download_create_info.h" 8 #include "chrome/browser/history/download_create_info.h"
9 #include "chrome/browser/history/history_marshaling.h" 9 #include "chrome/browser/history/history_marshaling.h"
10 #include "chrome/browser/download/download_item.h" 10 #include "chrome/browser/download/download_item.h"
11 #include "chrome/browser/profile.h" 11 #include "chrome/browser/profiles/profile.h"
12 12
13 // Our download table ID starts at 1, so we use 0 to represent a download that 13 // Our download table ID starts at 1, so we use 0 to represent a download that
14 // has started, but has not yet had its data persisted in the table. We use fake 14 // has started, but has not yet had its data persisted in the table. We use fake
15 // database handles in incognito mode starting at -1 and progressively getting 15 // database handles in incognito mode starting at -1 and progressively getting
16 // more negative. 16 // more negative.
17 // static 17 // static
18 const int DownloadHistory::kUninitializedHandle = 0; 18 const int DownloadHistory::kUninitializedHandle = 0;
19 19
20 DownloadHistory::DownloadHistory(Profile* profile) 20 DownloadHistory::DownloadHistory(Profile* profile)
21 : profile_(profile), 21 : profile_(profile),
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 const base::Time remove_end) { 108 const base::Time remove_end) {
109 // TODO(paulg) see bug 958058. EXPLICIT_ACCESS below is wrong. 109 // TODO(paulg) see bug 958058. EXPLICIT_ACCESS below is wrong.
110 HistoryService* hs = profile_->GetHistoryService(Profile::EXPLICIT_ACCESS); 110 HistoryService* hs = profile_->GetHistoryService(Profile::EXPLICIT_ACCESS);
111 if (hs) 111 if (hs)
112 hs->RemoveDownloadsBetween(remove_begin, remove_end); 112 hs->RemoveDownloadsBetween(remove_begin, remove_end);
113 } 113 }
114 114
115 int64 DownloadHistory::GetNextFakeDbHandle() { 115 int64 DownloadHistory::GetNextFakeDbHandle() {
116 return next_fake_db_handle_--; 116 return next_fake_db_handle_--;
117 } 117 }
OLDNEW
« no previous file with comments | « chrome/browser/download/download_file_manager.cc ('k') | chrome/browser/download/download_item.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698