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

Side by Side Diff: chrome/browser/sync_file_system/drive_backend/sync_engine_initializer.cc

Issue 437943002: [SyncFS] Remove usage of file task runner under drive_backend/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Work for nits Created 6 years, 4 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 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/sync_file_system/drive_backend/sync_engine_initializer. h" 5 #include "chrome/browser/sync_file_system/drive_backend/sync_engine_initializer. h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "chrome/browser/drive/drive_api_service.h" 10 #include "chrome/browser/drive/drive_api_service.h"
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 // The metadata seems to have been already initialized. Just return with OK. 80 // The metadata seems to have been already initialized. Just return with OK.
81 if (sync_context_->GetMetadataDatabase()) { 81 if (sync_context_->GetMetadataDatabase()) {
82 util::Log(logging::LOG_VERBOSE, FROM_HERE, 82 util::Log(logging::LOG_VERBOSE, FROM_HERE,
83 "[Initialize] Already initialized."); 83 "[Initialize] Already initialized.");
84 SyncTaskManager::NotifyTaskDone(token.Pass(), SYNC_STATUS_OK); 84 SyncTaskManager::NotifyTaskDone(token.Pass(), SYNC_STATUS_OK);
85 return; 85 return;
86 } 86 }
87 87
88 MetadataDatabase::Create( 88 MetadataDatabase::Create(
89 sync_context_->GetWorkerTaskRunner(), 89 sync_context_->GetWorkerTaskRunner(),
90 sync_context_->GetFileTaskRunner(),
91 database_path_, 90 database_path_,
92 env_override_, 91 env_override_,
93 base::Bind(&SyncEngineInitializer::DidCreateMetadataDatabase, 92 base::Bind(&SyncEngineInitializer::DidCreateMetadataDatabase,
94 weak_ptr_factory_.GetWeakPtr(), base::Passed(&token))); 93 weak_ptr_factory_.GetWeakPtr(), base::Passed(&token)));
95 } 94 }
96 95
97 scoped_ptr<MetadataDatabase> SyncEngineInitializer::PassMetadataDatabase() { 96 scoped_ptr<MetadataDatabase> SyncEngineInitializer::PassMetadataDatabase() {
98 return metadata_database_.Pass(); 97 return metadata_database_.Pass();
99 } 98 }
100 99
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after
367 return; 366 return;
368 } 367 }
369 368
370 util::Log(logging::LOG_VERBOSE, FROM_HERE, 369 util::Log(logging::LOG_VERBOSE, FROM_HERE,
371 "[Initialize] Completed successfully."); 370 "[Initialize] Completed successfully.");
372 SyncTaskManager::NotifyTaskDone(token.Pass(), SYNC_STATUS_OK); 371 SyncTaskManager::NotifyTaskDone(token.Pass(), SYNC_STATUS_OK);
373 } 372 }
374 373
375 } // namespace drive_backend 374 } // namespace drive_backend
376 } // namespace sync_file_system 375 } // namespace sync_file_system
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698