| 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" |
| 11 #include "base/message_loop_proxy.h" | 11 #include "base/message_loop_proxy.h" |
| 12 #include "base/task_runner_util.h" | 12 #include "base/task_runner_util.h" |
| 13 #include "base/threading/sequenced_worker_pool.h" | 13 #include "base/threading/sequenced_worker_pool.h" |
| 14 #include "base/values.h" | 14 #include "base/values.h" |
| 15 #include "chrome/browser/google_apis/drive_api_operations.h" | 15 #include "chrome/browser/google_apis/drive_api_operations.h" |
| 16 #include "chrome/browser/google_apis/drive_api_parser.h" | 16 #include "chrome/browser/google_apis/drive_api_parser.h" |
| 17 #include "chrome/browser/google_apis/gdata_wapi_parser.h" | 17 #include "chrome/browser/google_apis/gdata_wapi_parser.h" |
| 18 #include "chrome/browser/google_apis/operation_runner.h" | 18 #include "chrome/browser/google_apis/operation_runner.h" |
| 19 #include "chrome/browser/google_apis/time_util.h" | 19 #include "chrome/browser/google_apis/time_util.h" |
| 20 #include "chrome/browser/profiles/profile.h" | 20 #include "chrome/browser/profiles/profile.h" |
| 21 #include "chrome/common/net/url_util.h" | |
| 22 #include "content/public/browser/browser_thread.h" | 21 #include "content/public/browser/browser_thread.h" |
| 23 | 22 |
| 24 using content::BrowserThread; | 23 using content::BrowserThread; |
| 25 | 24 |
| 26 namespace google_apis { | 25 namespace google_apis { |
| 27 | 26 |
| 28 namespace { | 27 namespace { |
| 29 | 28 |
| 30 // OAuth2 scopes for Drive API. | 29 // OAuth2 scopes for Drive API. |
| 31 const char kDriveScope[] = "https://www.googleapis.com/auth/drive"; | 30 const char kDriveScope[] = "https://www.googleapis.com/auth/drive"; |
| (...skipping 457 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 489 } | 488 } |
| 490 | 489 |
| 491 void DriveAPIService::OnAuthenticationFailed(GDataErrorCode error) { | 490 void DriveAPIService::OnAuthenticationFailed(GDataErrorCode error) { |
| 492 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 491 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
| 493 FOR_EACH_OBSERVER( | 492 FOR_EACH_OBSERVER( |
| 494 DriveServiceObserver, observers_, | 493 DriveServiceObserver, observers_, |
| 495 OnAuthenticationFailed(error)); | 494 OnAuthenticationFailed(error)); |
| 496 } | 495 } |
| 497 | 496 |
| 498 } // namespace google_apis | 497 } // namespace google_apis |
| OLD | NEW |