Chromium Code Reviews| Index: chrome/browser/ui/ash/multi_user/multi_user_window_manager_chromeos.cc |
| diff --git a/chrome/browser/ui/ash/multi_user/multi_user_window_manager_chromeos.cc b/chrome/browser/ui/ash/multi_user/multi_user_window_manager_chromeos.cc |
| index bef7236f5695bf21d71ac30fff8af0385b574c1e..5c5533e5eb0bb4b7b636e08a5f877401e8abba31 100644 |
| --- a/chrome/browser/ui/ash/multi_user/multi_user_window_manager_chromeos.cc |
| +++ b/chrome/browser/ui/ash/multi_user/multi_user_window_manager_chromeos.cc |
| @@ -627,7 +627,11 @@ bool MultiUserWindowManagerChromeOS::ShowWindowForUserIntern( |
| void MultiUserWindowManagerChromeOS::SetWindowVisibility( |
| aura::Window* window, bool visible, int animation_time_in_ms) { |
| - if (window->IsVisible() == visible) |
| + // For a panel window, it's possible that this panel window is in the middle |
| + // of relayout animation because of hiding/reshowing shelf during profile |
| + // switch. Thus the window's visibility might not be its real visibility. See |
| + // crbug.com/564725 for more info. |
| + if (window->IsVisible() == visible && window->layer()->IsDrawn()) |
|
oshima
2016/02/11 23:31:56
I dug a bit more and I think the following is the
|
| return; |
| // Hiding a system modal dialog should not be allowed. Instead we switch to |
| @@ -778,10 +782,6 @@ void MultiUserWindowManagerChromeOS::SetWindowVisible( |
| window->Show(); |
| else |
| window->Hide(); |
| - |
| - // Make sure that animations have no influence on the window state after the |
| - // call. |
| - DCHECK_EQ(visible, window->IsVisible()); |
| } |
| int MultiUserWindowManagerChromeOS::GetAdjustedAnimationTimeInMS( |