Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(655)

Unified Diff: ash/wm/session_state_animator_impl.cc

Issue 2823343006: cros: Fix unlock crash with multi-display (Closed)
Patch Set: add comment for test Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/wm/session_state_animator.h ('k') | ash/wm/session_state_animator_impl_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/session_state_animator_impl.cc
diff --git a/ash/wm/session_state_animator_impl.cc b/ash/wm/session_state_animator_impl.cc
index d20515542a6eb833e4510353037bea1e0631d3a6..afe0bbfa31d667ca8e34e3e38784edac4194dca0 100644
--- a/ash/wm/session_state_animator_impl.cc
+++ b/ash/wm/session_state_animator_impl.cc
@@ -9,6 +9,7 @@
#include "ash/public/cpp/shell_window_ids.h"
#include "ash/shell.h"
#include "ash/wm/wm_window_animations.h"
+#include "base/barrier_closure.h"
#include "base/memory/ptr_util.h"
#include "ui/aura/client/aura_constants.h"
#include "ui/aura/window_event_dispatcher.h"
@@ -548,10 +549,12 @@ void SessionStateAnimatorImpl::StartAnimationWithCallback(
base::Closure callback) {
aura::Window::Windows containers;
GetContainers(container_mask, &containers);
+ base::Closure animation_done_closure =
+ base::BarrierClosure(containers.size(), callback);
for (aura::Window::Windows::const_iterator it = containers.begin();
it != containers.end(); ++it) {
ui::LayerAnimationObserver* observer =
- new CallbackAnimationObserver(callback);
+ new CallbackAnimationObserver(animation_done_closure);
RunAnimationForWindow(*it, type, speed, observer);
}
}
« no previous file with comments | « ash/wm/session_state_animator.h ('k') | ash/wm/session_state_animator_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698