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

Side by Side Diff: chrome/browser/history/delete_directive_handler.cc

Issue 12813004: Chromium style checker cleanup (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 years, 9 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/history/delete_directive_handler.h" 5 #include "chrome/browser/history/delete_directive_handler.h"
6 6
7 #include "base/json/json_writer.h" 7 #include "base/json/json_writer.h"
8 #include "base/rand_util.h" 8 #include "base/rand_util.h"
9 #include "base/time.h" 9 #include "base/time.h"
10 #include "base/values.h" 10 #include "base/values.h"
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 : delete_directive_handler_(delete_directive_handler), 74 : delete_directive_handler_(delete_directive_handler),
75 delete_directives_(delete_directive), 75 delete_directives_(delete_directive),
76 post_processing_action_(post_processing_action) {} 76 post_processing_action_(post_processing_action) {}
77 77
78 // Implements HistoryDBTask. 78 // Implements HistoryDBTask.
79 virtual bool RunOnDBThread(history::HistoryBackend* backend, 79 virtual bool RunOnDBThread(history::HistoryBackend* backend,
80 history::HistoryDatabase* db) OVERRIDE; 80 history::HistoryDatabase* db) OVERRIDE;
81 virtual void DoneRunOnMainThread() OVERRIDE; 81 virtual void DoneRunOnMainThread() OVERRIDE;
82 82
83 private: 83 private:
84 ~DeleteDirectiveTask() {} 84 virtual ~DeleteDirectiveTask() {}
85 85
86 // Process a list of global Id directives. Delete all visits to a URL in 86 // Process a list of global Id directives. Delete all visits to a URL in
87 // time ranges of directives if the timestamp of one visit matches with one 87 // time ranges of directives if the timestamp of one visit matches with one
88 // global id. 88 // global id.
89 void ProcessGlobalIdDeleteDirectives( 89 void ProcessGlobalIdDeleteDirectives(
90 history::HistoryBackend* history_backend, 90 history::HistoryBackend* history_backend,
91 const syncer::SyncDataList& global_id_directives); 91 const syncer::SyncDataList& global_id_directives);
92 92
93 // Process a list of time range directives, all history entries within the 93 // Process a list of time range directives, all history entries within the
94 // time ranges are deleted. |time_range_directives| should be sorted by 94 // time ranges are deleted. |time_range_directives| should be sorted by
(...skipping 279 matching lines...) Expand 10 before | Expand all | Expand 10 after
374 for (size_t i = 0; i < delete_directives.size(); ++i) { 374 for (size_t i = 0; i < delete_directives.size(); ++i) {
375 change_list.push_back( 375 change_list.push_back(
376 syncer::SyncChange(FROM_HERE, syncer::SyncChange::ACTION_DELETE, 376 syncer::SyncChange(FROM_HERE, syncer::SyncChange::ACTION_DELETE,
377 delete_directives[i])); 377 delete_directives[i]));
378 } 378 }
379 sync_processor_->ProcessSyncChanges(FROM_HERE, change_list); 379 sync_processor_->ProcessSyncChanges(FROM_HERE, change_list);
380 } 380 }
381 } 381 }
382 382
383 } // namespace history 383 } // namespace history
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698