| 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_misc.h" | 5 #include "chrome/browser/chromeos/extensions/file_manager/private_api_misc.h" |
| 6 | 6 |
| 7 #include "ash/frame/frame_util.h" | 7 #include "ash/frame/frame_util.h" |
| 8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
| 9 #include "base/prefs/pref_service.h" | 9 #include "base/prefs/pref_service.h" |
| 10 #include "base/strings/stringprintf.h" | 10 #include "base/strings/stringprintf.h" |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 profile_info->is_current_profile = true; | 90 profile_info->is_current_profile = true; |
| 91 | 91 |
| 92 result_profiles.push_back(profile_info); | 92 result_profiles.push_back(profile_info); |
| 93 } | 93 } |
| 94 | 94 |
| 95 return result_profiles; | 95 return result_profiles; |
| 96 } | 96 } |
| 97 } // namespace | 97 } // namespace |
| 98 | 98 |
| 99 bool FileManagerPrivateLogoutUserForReauthenticationFunction::RunSync() { | 99 bool FileManagerPrivateLogoutUserForReauthenticationFunction::RunSync() { |
| 100 user_manager::User* user = | 100 const user_manager::User* user = |
| 101 chromeos::ProfileHelper::Get()->GetUserByProfile(GetProfile()); | 101 chromeos::ProfileHelper::Get()->GetUserByProfile(GetProfile()); |
| 102 if (user) { | 102 if (user) { |
| 103 user_manager::UserManager::Get()->SaveUserOAuthStatus( | 103 user_manager::UserManager::Get()->SaveUserOAuthStatus( |
| 104 user->email(), user_manager::User::OAUTH2_TOKEN_STATUS_INVALID); | 104 user->email(), user_manager::User::OAUTH2_TOKEN_STATUS_INVALID); |
| 105 } | 105 } |
| 106 | 106 |
| 107 chrome::AttemptUserExit(); | 107 chrome::AttemptUserExit(); |
| 108 return true; | 108 return true; |
| 109 } | 109 } |
| 110 | 110 |
| (...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 454 return true; | 454 return true; |
| 455 } | 455 } |
| 456 | 456 |
| 457 void FileManagerPrivateGetMimeTypeFunction::OnGetMimeType( | 457 void FileManagerPrivateGetMimeTypeFunction::OnGetMimeType( |
| 458 const std::string& mimeType) { | 458 const std::string& mimeType) { |
| 459 SetResult(new base::StringValue(mimeType)); | 459 SetResult(new base::StringValue(mimeType)); |
| 460 SendResponse(true); | 460 SendResponse(true); |
| 461 } | 461 } |
| 462 | 462 |
| 463 } // namespace extensions | 463 } // namespace extensions |
| OLD | NEW |