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

Side by Side Diff: chrome/browser/google_apis/gdata_wapi_service.cc

Issue 12246002: Implement GetUploadStatusOperation on GData WAPI. (Closed) Base URL: http://git.chromium.org/chromium/src.git@b148632_create_base_operation
Patch Set: Fix mock server's behavior, as well as empty Range header handling. Created 7 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/google_apis/gdata_wapi_service.h" 5 #include "chrome/browser/google_apis/gdata_wapi_service.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 429 matching lines...) Expand 10 before | Expand all | Expand 10 after
440 440
441 void GDataWapiService::GetUploadStatus( 441 void GDataWapiService::GetUploadStatus(
442 UploadMode upload_mode, 442 UploadMode upload_mode,
443 const FilePath& drive_file_path, 443 const FilePath& drive_file_path,
444 const GURL& upload_url, 444 const GURL& upload_url,
445 int64 content_length, 445 int64 content_length,
446 const UploadRangeCallback& callback) { 446 const UploadRangeCallback& callback) {
447 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 447 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
448 DCHECK(!callback.is_null()); 448 DCHECK(!callback.is_null());
449 449
450 // TODO(hidehiko): Implement this. 450 runner_->StartOperationWithRetry(
451 NOTREACHED(); 451 new GetUploadStatusOperation(operation_registry(),
452 url_request_context_getter_,
453 callback,
454 upload_mode,
455 drive_file_path,
456 upload_url,
457 content_length));
452 } 458 }
453 459
454 void GDataWapiService::AuthorizeApp(const GURL& edit_url, 460 void GDataWapiService::AuthorizeApp(const GURL& edit_url,
455 const std::string& app_id, 461 const std::string& app_id,
456 const AuthorizeAppCallback& callback) { 462 const AuthorizeAppCallback& callback) {
457 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 463 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
458 DCHECK(!callback.is_null()); 464 DCHECK(!callback.is_null());
459 465
460 runner_->StartOperationWithRetry( 466 runner_->StartOperationWithRetry(
461 new AuthorizeAppOperation( 467 new AuthorizeAppOperation(
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
505 } 511 }
506 512
507 void GDataWapiService::OnProgressUpdate( 513 void GDataWapiService::OnProgressUpdate(
508 const OperationProgressStatusList& list) { 514 const OperationProgressStatusList& list) {
509 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 515 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
510 FOR_EACH_OBSERVER( 516 FOR_EACH_OBSERVER(
511 DriveServiceObserver, observers_, OnProgressUpdate(list)); 517 DriveServiceObserver, observers_, OnProgressUpdate(list));
512 } 518 }
513 519
514 } // namespace google_apis 520 } // namespace google_apis
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698