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

Side by Side Diff: ui/views/widget/native_widget_aura_window_observer.h

Issue 11421194: Hook up the FocusController behind a flag. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years 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 | Annotate | Revision Log
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_WIDGET_NATIVE_WIDGET_AURA_WINDOW_OBSERVER_H_ 5 #ifndef UI_VIEWS_WIDGET_NATIVE_WIDGET_AURA_WINDOW_OBSERVER_H_
6 #define UI_VIEWS_WIDGET_NATIVE_WIDGET_AURA_WINDOW_OBSERVER_H_ 6 #define UI_VIEWS_WIDGET_NATIVE_WIDGET_AURA_WINDOW_OBSERVER_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "ui/aura/client/activation_change_observer.h"
10 #include "ui/aura/window_observer.h" 9 #include "ui/aura/window_observer.h"
11 #include "ui/gfx/native_widget_types.h" 10 #include "ui/gfx/native_widget_types.h"
11 #include "ui/views/corewm/activation_change_shim.h"
12 #include "ui/views/widget/native_widget_private.h" 12 #include "ui/views/widget/native_widget_private.h"
13 13
14 namespace views { 14 namespace views {
15 15
16 // A helper class shared between NativeWidgetAura implementations. Used when 16 // A helper class shared between NativeWidgetAura implementations. Used when
17 // SetInactiveRenderingDisabled() is invoked to track when active status 17 // SetInactiveRenderingDisabled() is invoked to track when active status
18 // changes in such a way that we should enable inactive rendering. 18 // changes in such a way that we should enable inactive rendering.
19 class NativeWidgetAuraWindowObserver 19 class NativeWidgetAuraWindowObserver
20 : public aura::WindowObserver, 20 : public aura::WindowObserver,
21 public aura::client::ActivationChangeObserver { 21 public corewm::ActivationChangeShim {
22 public: 22 public:
23 explicit NativeWidgetAuraWindowObserver( 23 explicit NativeWidgetAuraWindowObserver(
24 gfx::NativeView native_view, 24 gfx::NativeView native_view,
25 internal::NativeWidgetDelegate* delegate); 25 internal::NativeWidgetDelegate* delegate);
26 virtual ~NativeWidgetAuraWindowObserver(); 26 virtual ~NativeWidgetAuraWindowObserver();
27 27
28 // Overridden from aura::client::ActivationChangeObserver: 28 // Overridden from aura::client::ActivationChangeObserver:
29 virtual void OnWindowActivated(aura::Window* active, 29 virtual void OnWindowActivated(aura::Window* active,
30 aura::Window* old_active) OVERRIDE; 30 aura::Window* old_active) OVERRIDE;
31 31
32 // Overridden from aura::WindowObserver: 32 // Overridden from aura::WindowObserver:
33 virtual void OnWindowRemovingFromRootWindow(aura::Window* window) OVERRIDE; 33 virtual void OnWindowRemovingFromRootWindow(aura::Window* window) OVERRIDE;
34 34
35 private: 35 private:
36 void CleanUpObservers(); 36 void CleanUpObservers();
37 37
38 gfx::NativeView native_view_; 38 gfx::NativeView native_view_;
39 internal::NativeWidgetDelegate* delegate_; 39 internal::NativeWidgetDelegate* delegate_;
40 40
41 DISALLOW_COPY_AND_ASSIGN(NativeWidgetAuraWindowObserver); 41 DISALLOW_COPY_AND_ASSIGN(NativeWidgetAuraWindowObserver);
42 }; 42 };
43 43
44 } // namespace views 44 } // namespace views
45 45
46 #endif // UI_VIEWS_WIDGET_NATIVE_WIDGET_AURA_WINDOW_OBSERVER_H_ 46 #endif // UI_VIEWS_WIDGET_NATIVE_WIDGET_AURA_WINDOW_OBSERVER_H_
OLDNEW
« no previous file with comments | « ui/views/widget/native_widget_aura.cc ('k') | ui/views/widget/native_widget_aura_window_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698