| OLD | NEW |
| 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/drive_api_service.h" | 5 #include "chrome/browser/google_apis/drive_api_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 304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 315 DCHECK(!callback.is_null()); | 315 DCHECK(!callback.is_null()); |
| 316 | 316 |
| 317 runner_->StartOperationWithRetry( | 317 runner_->StartOperationWithRetry( |
| 318 new GetAboutOperation( | 318 new GetAboutOperation( |
| 319 operation_registry(), | 319 operation_registry(), |
| 320 url_request_context_getter_, | 320 url_request_context_getter_, |
| 321 url_generator_, | 321 url_generator_, |
| 322 base::Bind(&ParseAccounetMetadataAndRun, callback))); | 322 base::Bind(&ParseAccounetMetadataAndRun, callback))); |
| 323 } | 323 } |
| 324 | 324 |
| 325 void DriveAPIService::GetAboutResource( |
| 326 const GetAboutResourceCallback& callback) { |
| 327 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
| 328 DCHECK(!callback.is_null()); |
| 329 |
| 330 // TODO(hidehiko): Implement this. |
| 331 NOTREACHED(); |
| 332 } |
| 333 |
| 325 void DriveAPIService::GetAppList(const GetAppListCallback& callback) { | 334 void DriveAPIService::GetAppList(const GetAppListCallback& callback) { |
| 326 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 335 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
| 327 DCHECK(!callback.is_null()); | 336 DCHECK(!callback.is_null()); |
| 328 | 337 |
| 329 runner_->StartOperationWithRetry(new GetApplistOperation( | 338 runner_->StartOperationWithRetry(new GetApplistOperation( |
| 330 operation_registry(), | 339 operation_registry(), |
| 331 url_request_context_getter_, | 340 url_request_context_getter_, |
| 332 url_generator_, | 341 url_generator_, |
| 333 base::Bind(&ParseAppListAndRun, callback))); | 342 base::Bind(&ParseAppListAndRun, callback))); |
| 334 } | 343 } |
| (...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 547 } | 556 } |
| 548 | 557 |
| 549 void DriveAPIService::OnProgressUpdate( | 558 void DriveAPIService::OnProgressUpdate( |
| 550 const OperationProgressStatusList& list) { | 559 const OperationProgressStatusList& list) { |
| 551 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 560 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
| 552 FOR_EACH_OBSERVER( | 561 FOR_EACH_OBSERVER( |
| 553 DriveServiceObserver, observers_, OnProgressUpdate(list)); | 562 DriveServiceObserver, observers_, OnProgressUpdate(list)); |
| 554 } | 563 } |
| 555 | 564 |
| 556 } // namespace google_apis | 565 } // namespace google_apis |
| OLD | NEW |