| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef CHROME_BROWSER_UI_ASH_MULTI_USER_USER_SWITCH_UTIL_H_ | 5 #ifndef CHROME_BROWSER_UI_ASH_MULTI_USER_USER_SWITCH_UTIL_H_ |
| 6 #define CHROME_BROWSER_UI_ASH_MULTI_USER_USER_SWITCH_UTIL_H_ | 6 #define CHROME_BROWSER_UI_ASH_MULTI_USER_USER_SWITCH_UTIL_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 | 9 |
| 10 // Tries to switch to a new user by first checking if desktop casting / sharing | 10 // Tries to switch to a new user by first checking if desktop casting / sharing |
| 11 // is going on, and let the user decide if he wants to terminate it or not. | 11 // is going on, and let the user decide if he wants to terminate it or not. |
| 12 // After terminating any desktop sharing operations, the |switch_user| function | 12 // After terminating any desktop sharing operations, the |switch_user| function |
| 13 // will be called. | 13 // will be called. |
| 14 void TrySwitchingActiveUser(const base::Callback<void()> switch_user); | 14 void TrySwitchingActiveUser(const base::Callback<void()> switch_user); |
| 15 | 15 |
| 16 // Terminates the "DesktopCastingWarning" dialog from a unit tests and |accept|s | |
| 17 // it. False will be returned if there was no dialog shown. | |
| 18 bool TestAndTerminateDesktopCastingWarningForTest(bool accept); | |
| 19 | |
| 20 #endif // CHROME_BROWSER_UI_ASH_MULTI_USER_USER_SWITCH_UTIL_H_ | 16 #endif // CHROME_BROWSER_UI_ASH_MULTI_USER_USER_SWITCH_UTIL_H_ |
| OLD | NEW |