| OLD | NEW |
| 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/extensions/file_manager/private_api_mount.h" | 5 #include "chrome/browser/chromeos/extensions/file_manager/private_api_mount.h" |
| 6 | 6 |
| 7 #include "base/format_macros.h" | 7 #include "base/format_macros.h" |
| 8 #include "base/values.h" | 8 #include "base/values.h" |
| 9 #include "chrome/browser/chromeos/drive/drive_integration_service.h" | 9 #include "chrome/browser/chromeos/drive/drive_integration_service.h" |
| 10 #include "chrome/browser/chromeos/drive/file_system_interface.h" | 10 #include "chrome/browser/chromeos/drive/file_system_interface.h" |
| (...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 193 request_id(), | 193 request_id(), |
| 194 mount_path.c_str()); | 194 mount_path.c_str()); |
| 195 set_log_on_completion(true); | 195 set_log_on_completion(true); |
| 196 | 196 |
| 197 std::vector<GURL> file_paths; | 197 std::vector<GURL> file_paths; |
| 198 file_paths.push_back(GURL(mount_path)); | 198 file_paths.push_back(GURL(mount_path)); |
| 199 util::GetSelectedFileInfo( | 199 util::GetSelectedFileInfo( |
| 200 render_view_host(), | 200 render_view_host(), |
| 201 profile(), | 201 profile(), |
| 202 file_paths, | 202 file_paths, |
| 203 true, // for_opening | 203 util::NEED_LOCAL_PATH_FOR_OPENING, |
| 204 base::Bind(&RemoveMountFunction::GetSelectedFileInfoResponse, this)); | 204 base::Bind(&RemoveMountFunction::GetSelectedFileInfoResponse, this)); |
| 205 return true; | 205 return true; |
| 206 } | 206 } |
| 207 | 207 |
| 208 void RemoveMountFunction::GetSelectedFileInfoResponse( | 208 void RemoveMountFunction::GetSelectedFileInfoResponse( |
| 209 const std::vector<ui::SelectedFileInfo>& files) { | 209 const std::vector<ui::SelectedFileInfo>& files) { |
| 210 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 210 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
| 211 | 211 |
| 212 if (files.size() != 1) { | 212 if (files.size() != 1) { |
| 213 SendResponse(false); | 213 SendResponse(false); |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 261 name().c_str(), | 261 name().c_str(), |
| 262 request_id(), | 262 request_id(), |
| 263 log_string.c_str(), | 263 log_string.c_str(), |
| 264 mount_points.size()); | 264 mount_points.size()); |
| 265 | 265 |
| 266 SendResponse(true); | 266 SendResponse(true); |
| 267 return true; | 267 return true; |
| 268 } | 268 } |
| 269 | 269 |
| 270 } // namespace file_manager | 270 } // namespace file_manager |
| OLD | NEW |