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/chromeos/drive/file_task_executor.h" | 5 #include "chrome/browser/chromeos/drive/file_task_executor.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/json/json_writer.h" | 10 #include "base/json/json_writer.h" |
11 #include "base/string_util.h" | 11 #include "base/string_util.h" |
12 #include "chrome/browser/chromeos/drive/drive.pb.h" | 12 #include "chrome/browser/chromeos/drive/drive.pb.h" |
13 #include "chrome/browser/chromeos/drive/drive_integration_service.h" | 13 #include "chrome/browser/chromeos/drive/drive_integration_service.h" |
14 #include "chrome/browser/chromeos/drive/file_system_interface.h" | 14 #include "chrome/browser/chromeos/drive/file_system_interface.h" |
15 #include "chrome/browser/chromeos/extensions/file_manager/file_browser_private_a
pi.h" | 15 #include "chrome/browser/chromeos/extensions/file_manager/file_browser_private_a
pi.h" |
16 #include "chrome/browser/google_apis/drive_service_interface.h" | 16 #include "chrome/browser/google_apis/drive_service_interface.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/profiles/profile.h" | 18 #include "chrome/browser/profiles/profile.h" |
19 #include "chrome/browser/profiles/profile_manager.h" | 19 #include "chrome/browser/profiles/profile_manager.h" |
20 #include "chrome/browser/ui/browser.h" | 20 #include "chrome/browser/ui/browser.h" |
21 #include "chrome/browser/ui/browser_finder.h" | 21 #include "chrome/browser/ui/browser_finder.h" |
22 #include "chrome/browser/ui/browser_tabstrip.h" | 22 #include "chrome/browser/ui/browser_tabstrip.h" |
23 #include "chrome/browser/ui/browser_window.h" | 23 #include "chrome/browser/ui/browser_window.h" |
24 #include "content/public/browser/browser_thread.h" | 24 #include "content/public/browser/browser_thread.h" |
25 #include "webkit/browser/fileapi/file_system_url.h" | 25 #include "webkit/browser/fileapi/file_system_url.h" |
26 #include "webkit/fileapi/file_system_types.h" | 26 #include "webkit/common/fileapi/file_system_types.h" |
27 #include "webkit/fileapi/file_system_util.h" | 27 #include "webkit/common/fileapi/file_system_util.h" |
28 | 28 |
29 using file_handler_util::FileTaskExecutor; | 29 using file_handler_util::FileTaskExecutor; |
30 using fileapi::FileSystemURL; | 30 using fileapi::FileSystemURL; |
31 | 31 |
32 namespace drive { | 32 namespace drive { |
33 | 33 |
34 FileTaskExecutor::FileTaskExecutor(Profile* profile, | 34 FileTaskExecutor::FileTaskExecutor(Profile* profile, |
35 const std::string& app_id, | 35 const std::string& app_id, |
36 const std::string& action_id) | 36 const std::string& action_id) |
37 : file_handler_util::FileTaskExecutor(profile, GURL(), "", app_id), | 37 : file_handler_util::FileTaskExecutor(profile, GURL(), "", app_id), |
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
146 | 146 |
147 void FileTaskExecutor::Done(bool success) { | 147 void FileTaskExecutor::Done(bool success) { |
148 DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); | 148 DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI)); |
149 current_index_ = 0; | 149 current_index_ = 0; |
150 if (!done_.is_null()) | 150 if (!done_.is_null()) |
151 done_.Run(success); | 151 done_.Run(success); |
152 done_.Reset(); | 152 done_.Reset(); |
153 } | 153 } |
154 | 154 |
155 } // namespace drive | 155 } // namespace drive |
OLD | NEW |