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

Side by Side Diff: components/mus/ws/focus_controller.cc

Issue 1863523006: mash: Make system tray bubble close when another window is activated (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase again Created 4 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "components/mus/ws/focus_controller.h" 5 #include "components/mus/ws/focus_controller.h"
6 6
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "components/mus/public/interfaces/window_manager.mojom.h" 8 #include "components/mus/public/interfaces/window_manager.mojom.h"
9 #include "components/mus/ws/focus_controller_delegate.h" 9 #include "components/mus/ws/focus_controller_delegate.h"
10 #include "components/mus/ws/focus_controller_observer.h" 10 #include "components/mus/ws/focus_controller_observer.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 DCHECK(root_); 68 DCHECK(root_);
69 } 69 }
70 70
71 FocusController::~FocusController() { 71 FocusController::~FocusController() {
72 } 72 }
73 73
74 void FocusController::SetFocusedWindow(ServerWindow* window) { 74 void FocusController::SetFocusedWindow(ServerWindow* window) {
75 if (GetFocusedWindow() == window) 75 if (GetFocusedWindow() == window)
76 return; 76 return;
77 77
78 // TODO(jamescook): Failures to set focus should be propagated back to the
sky 2016/04/07 17:55:10 Nuke this TODO. I have a patch out to fix.
James Cook 2016/04/07 20:43:43 Done.
79 // client so it doesn't get out of sync. http://crbug.com/600869
78 SetFocusedWindowImpl(FocusControllerChangeSource::EXPLICIT, window); 80 SetFocusedWindowImpl(FocusControllerChangeSource::EXPLICIT, window);
79 } 81 }
80 82
81 ServerWindow* FocusController::GetFocusedWindow() { 83 ServerWindow* FocusController::GetFocusedWindow() {
82 return focused_window_; 84 return focused_window_;
83 } 85 }
84 86
85 void FocusController::ActivateNextWindow() { 87 void FocusController::ActivateNextWindow() {
86 WindowTreeIterator iter(root_); 88 WindowTreeIterator iter(root_);
87 ServerWindow* activate = active_window_; 89 ServerWindow* activate = active_window_;
(...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 } 302 }
301 303
302 void FocusController::OnDrawnStateChanged(ServerWindow* ancestor, 304 void FocusController::OnDrawnStateChanged(ServerWindow* ancestor,
303 ServerWindow* window, 305 ServerWindow* window,
304 bool is_drawn) { 306 bool is_drawn) {
305 // DCHECK(false); TODO(sadrul): 307 // DCHECK(false); TODO(sadrul):
306 } 308 }
307 309
308 } // namespace ws 310 } // namespace ws
309 } // namespace mus 311 } // namespace mus
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698