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

Side by Side Diff: ui/views/corewm/focus_controller.h

Issue 14222019: Trying to activate a window in a workspace other than the current is ignored while a system modal d… (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: nits Created 7 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
« no previous file with comments | « ui/aura/client/activation_change_observer.h ('k') | ui/views/corewm/focus_controller.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 UI_VIEWS_COREWM_FOCUS_CONTROLLER_H_ 5 #ifndef UI_VIEWS_COREWM_FOCUS_CONTROLLER_H_
6 #define UI_VIEWS_COREWM_FOCUS_CONTROLLER_H_ 6 #define UI_VIEWS_COREWM_FOCUS_CONTROLLER_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/scoped_observer.h" 9 #include "base/scoped_observer.h"
10 #include "ui/aura/client/activation_client.h" 10 #include "ui/aura/client/activation_client.h"
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 77
78 // Overridden from aura::WindowObserver: 78 // Overridden from aura::WindowObserver:
79 virtual void OnWindowVisibilityChanged(aura::Window* window, 79 virtual void OnWindowVisibilityChanged(aura::Window* window,
80 bool visible) OVERRIDE; 80 bool visible) OVERRIDE;
81 virtual void OnWindowDestroying(aura::Window* window) OVERRIDE; 81 virtual void OnWindowDestroying(aura::Window* window) OVERRIDE;
82 virtual void OnWindowHierarchyChanging( 82 virtual void OnWindowHierarchyChanging(
83 const HierarchyChangeParams& params) OVERRIDE; 83 const HierarchyChangeParams& params) OVERRIDE;
84 virtual void OnWindowHierarchyChanged( 84 virtual void OnWindowHierarchyChanged(
85 const HierarchyChangeParams& params) OVERRIDE; 85 const HierarchyChangeParams& params) OVERRIDE;
86 86
87 // Internal implementations that set the focused/active windows, fire events 87 // Internal implementation that sets the focused window, fires events etc.
88 // etc. These functions must be called with valid focusable/activatable 88 // This function must be called with a valid focusable window.
89 // windows.
90 void SetFocusedWindow(aura::Window* window); 89 void SetFocusedWindow(aura::Window* window);
91 void SetActiveWindow(aura::Window* window); 90
91 // Internal implementation that sets the active window, fires events etc.
92 // This function must be called with a valid |activatable_window|.
93 // |requested window| refers to the window that was passed in to an external
94 // request (e.g. FocusWindow or ActivateWindow). It may be NULL, e.g. if
95 // SetActiveWindow was not called by an external request. |activatable_window|
96 // refers to the actual window to be activated, which may be different.
97 void SetActiveWindow(aura::Window* requested_window,
98 aura::Window* activatable_window);
92 99
93 // Called when a window's disposition changed such that it and its hierarchy 100 // Called when a window's disposition changed such that it and its hierarchy
94 // are no longer focusable/activatable. |next| is a valid window that is used 101 // are no longer focusable/activatable. |next| is a valid window that is used
95 // as a starting point for finding a window to focus next based on rules. 102 // as a starting point for finding a window to focus next based on rules.
96 void WindowLostFocusFromDispositionChange(aura::Window* window, 103 void WindowLostFocusFromDispositionChange(aura::Window* window,
97 aura::Window* next); 104 aura::Window* next);
98 105
99 // Called when an attempt is made to focus or activate a window via an input 106 // Called when an attempt is made to focus or activate a window via an input
100 // event targeted at that window. Rules determine the best focusable window 107 // event targeted at that window. Rules determine the best focusable window
101 // for the input window. 108 // for the input window.
(...skipping 12 matching lines...) Expand all
114 121
115 ScopedObserver<aura::Window, aura::WindowObserver> observer_manager_; 122 ScopedObserver<aura::Window, aura::WindowObserver> observer_manager_;
116 123
117 DISALLOW_COPY_AND_ASSIGN(FocusController); 124 DISALLOW_COPY_AND_ASSIGN(FocusController);
118 }; 125 };
119 126
120 } // namespace corewm 127 } // namespace corewm
121 } // namespace views 128 } // namespace views
122 129
123 #endif // UI_VIEWS_COREWM_FOCUS_CONTROLLER_H_ 130 #endif // UI_VIEWS_COREWM_FOCUS_CONTROLLER_H_
OLDNEW
« no previous file with comments | « ui/aura/client/activation_change_observer.h ('k') | ui/views/corewm/focus_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698