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

Side by Side Diff: sync/api/attachments/fake_attachment_service.cc

Issue 270633005: Move code from sync/api/attachments to sync/internal_api/attachments. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Drop some unneeded deps and trim DEPS. Created 6 years, 7 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "sync/api/attachments/fake_attachment_service.h" 5 #include "sync/api/attachments/fake_attachment_service.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/message_loop/message_loop.h" 8 #include "base/message_loop/message_loop.h"
9 #include "sync/api/attachments/attachment.h" 9 #include "sync/api/attachments/attachment.h"
10 #include "sync/api/attachments/fake_attachment_store.h" 10 #include "sync/internal_api/public/attachments/fake_attachment_store.h"
11 #include "sync/api/attachments/fake_attachment_uploader.h" 11 #include "sync/internal_api/public/attachments/fake_attachment_uploader.h"
12 12
13 namespace syncer { 13 namespace syncer {
14 14
15 FakeAttachmentService::FakeAttachmentService( 15 FakeAttachmentService::FakeAttachmentService(
16 scoped_ptr<AttachmentStore> attachment_store, 16 scoped_ptr<AttachmentStore> attachment_store,
17 scoped_ptr<AttachmentUploader> attachment_uploader) 17 scoped_ptr<AttachmentUploader> attachment_uploader)
18 : attachment_store_(attachment_store.Pass()), 18 : attachment_store_(attachment_store.Pass()),
19 attachment_uploader_(attachment_uploader.Pass()), 19 attachment_uploader_(attachment_uploader.Pass()),
20 weak_ptr_factory_(this) { 20 weak_ptr_factory_(this) {
21 DCHECK(CalledOnValidThread()); 21 DCHECK(CalledOnValidThread());
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 AttachmentService::STORE_UNSPECIFIED_ERROR; 118 AttachmentService::STORE_UNSPECIFIED_ERROR;
119 if (result == AttachmentStore::SUCCESS) { 119 if (result == AttachmentStore::SUCCESS) {
120 store_result = AttachmentService::STORE_SUCCESS; 120 store_result = AttachmentService::STORE_SUCCESS;
121 } 121 }
122 // TODO(maniscalco): Deal with case where an error occurred (bug 361251). 122 // TODO(maniscalco): Deal with case where an error occurred (bug 361251).
123 base::MessageLoop::current()->PostTask(FROM_HERE, 123 base::MessageLoop::current()->PostTask(FROM_HERE,
124 base::Bind(callback, store_result)); 124 base::Bind(callback, store_result));
125 } 125 }
126 126
127 } // namespace syncer 127 } // namespace syncer
OLDNEW
« no previous file with comments | « components/sync_driver/generic_change_processor_unittest.cc ('k') | sync/api/attachments/fake_attachment_store.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698