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

Unified Diff: chrome/browser/sync/profile_sync_components_factory_impl.cc

Issue 548373003: Move AttachmentStore ownership to datatype (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Changes after feedback. Created 6 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/sync/profile_sync_components_factory_impl.cc
diff --git a/chrome/browser/sync/profile_sync_components_factory_impl.cc b/chrome/browser/sync/profile_sync_components_factory_impl.cc
index 52390b06fd32fca81e5e86cd7c7baacc9ce4d9f9..09b2d08de440bac17bcec3051c4c1143ec90d194 100644
--- a/chrome/browser/sync/profile_sync_components_factory_impl.cc
+++ b/chrome/browser/sync/profile_sync_components_factory_impl.cc
@@ -593,13 +593,9 @@ OAuth2TokenService* TokenServiceProvider::GetTokenService() {
scoped_ptr<syncer::AttachmentService>
ProfileSyncComponentsFactoryImpl::CreateAttachmentService(
+ const scoped_refptr<syncer::AttachmentStore>& attachment_store,
const syncer::UserShare& user_share,
syncer::AttachmentService::Delegate* delegate) {
-
- scoped_ptr<syncer::AttachmentStore> attachment_store(
- new syncer::FakeAttachmentStore(
- BrowserThread::GetMessageLoopProxyForThread(BrowserThread::FILE)));
-
scoped_ptr<syncer::AttachmentUploader> attachment_uploader;
scoped_ptr<syncer::AttachmentDownloader> attachment_downloader;
// Only construct an AttachmentUploader and AttachmentDownload if we have sync
@@ -635,7 +631,7 @@ ProfileSyncComponentsFactoryImpl::CreateAttachmentService(
}
scoped_ptr<syncer::AttachmentService> attachment_service(
- new syncer::AttachmentServiceImpl(attachment_store.Pass(),
+ new syncer::AttachmentServiceImpl(attachment_store,
attachment_uploader.Pass(),
attachment_downloader.Pass(),
delegate));
« no previous file with comments | « chrome/browser/sync/profile_sync_components_factory_impl.h ('k') | chrome/browser/sync/profile_sync_components_factory_mock.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698