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

Side by Side Diff: chrome/browser/chromeos/drive/sync/entry_update_performer.cc

Issue 881403003: Rename gdata_errorcode.h to drive_api_error_codes.h (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix typos in BUILD.gn Created 5 years, 10 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
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/chromeos/drive/sync/entry_update_performer.h" 5 #include "chrome/browser/chromeos/drive/sync/entry_update_performer.h"
6 6
7 #include "base/callback_helpers.h" 7 #include "base/callback_helpers.h"
8 #include "base/files/file_util.h" 8 #include "base/files/file_util.h"
9 #include "chrome/browser/chromeos/drive/change_list_loader.h" 9 #include "chrome/browser/chromeos/drive/change_list_loader.h"
10 #include "chrome/browser/chromeos/drive/drive.pb.h" 10 #include "chrome/browser/chromeos/drive/drive.pb.h"
(...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after
351 weak_ptr_factory_.GetWeakPtr(), 351 weak_ptr_factory_.GetWeakPtr(),
352 context, callback, local_state->entry.local_id(), 352 context, callback, local_state->entry.local_id(),
353 base::Passed(scoped_ptr<base::ScopedClosureRunner>()))); 353 base::Passed(scoped_ptr<base::ScopedClosureRunner>())));
354 } 354 }
355 355
356 void EntryUpdatePerformer::UpdateEntryAfterUpdateResource( 356 void EntryUpdatePerformer::UpdateEntryAfterUpdateResource(
357 const ClientContext& context, 357 const ClientContext& context,
358 const FileOperationCallback& callback, 358 const FileOperationCallback& callback,
359 const std::string& local_id, 359 const std::string& local_id,
360 scoped_ptr<base::ScopedClosureRunner> loader_lock, 360 scoped_ptr<base::ScopedClosureRunner> loader_lock,
361 google_apis::GDataErrorCode status, 361 google_apis::DriveApiErrorCode status,
362 scoped_ptr<google_apis::FileResource> entry) { 362 scoped_ptr<google_apis::FileResource> entry) {
363 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 363 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
364 DCHECK(!callback.is_null()); 364 DCHECK(!callback.is_null());
365 365
366 if (status == google_apis::HTTP_FORBIDDEN) { 366 if (status == google_apis::HTTP_FORBIDDEN) {
367 // Editing this entry is not allowed, revert local changes. 367 // Editing this entry is not allowed, revert local changes.
368 entry_revert_performer_->RevertEntry(local_id, context, callback); 368 entry_revert_performer_->RevertEntry(local_id, context, callback);
369 return; 369 return;
370 } 370 }
371 371
(...skipping 25 matching lines...) Expand all
397 FileError error) { 397 FileError error) {
398 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 398 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
399 DCHECK(!callback.is_null()); 399 DCHECK(!callback.is_null());
400 400
401 delegate_->OnFileChangedByOperation(*changed_files); 401 delegate_->OnFileChangedByOperation(*changed_files);
402 callback.Run(error); 402 callback.Run(error);
403 } 403 }
404 404
405 } // namespace internal 405 } // namespace internal
406 } // namespace drive 406 } // namespace drive
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698