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

Unified Diff: components/mus/public/cpp/lib/window_tree_client_impl.cc

Issue 2021383002: Update WindowTreeClientImpl OnWindowDestroying (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/mus/public/cpp/lib/window_tree_client_impl.cc
diff --git a/components/mus/public/cpp/lib/window_tree_client_impl.cc b/components/mus/public/cpp/lib/window_tree_client_impl.cc
index 463cd27eeaa2f44af1dd53654be70d977a4ded47..6735cd405ea3ed75799bae65dbb77742b237748f 100644
--- a/components/mus/public/cpp/lib/window_tree_client_impl.cc
+++ b/components/mus/public/cpp/lib/window_tree_client_impl.cc
@@ -434,15 +434,13 @@ void WindowTreeClientImpl::AddWindow(Window* window) {
}
void WindowTreeClientImpl::OnWindowDestroying(Window* window) {
- // TODO(jonross): Also clear the focused window (crbug.com/611983)
if (window == capture_window_) {
- InFlightCaptureChange reset_change(this, nullptr);
- ApplyServerChangeToExistingInFlightChange(reset_change);
- // Normally just updating the queued changes is sufficient. However since
sadrul 2016/05/31 18:29:03 Would it be possible to write a test for this chan
jonross 2016/05/31 19:34:01 Pre-existing tests have coverage: MenuRunnerTest.W
+ // Normally the queue updates itself upon window destruction. However since
// |window| is being destroyed, it will not be possible to notify its
// observers of the lost capture. Update local state now.
LocalSetCapture(nullptr);
}
+ // For |focused_window_| window destruction clears the entire focus state.
}
void WindowTreeClientImpl::OnWindowDestroyed(Window* window) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698