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

Side by Side Diff: ui/aura_shell/shadow_controller.h

Issue 8771015: Rename Desktop->RootWindow. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 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
« no previous file with comments | « ui/aura_shell/root_window_layout_manager.cc ('k') | ui/aura_shell/shadow_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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_AURA_SHELL_SHADOW_CONTROLLER_H_ 5 #ifndef UI_AURA_SHELL_SHADOW_CONTROLLER_H_
6 #define UI_AURA_SHELL_SHADOW_CONTROLLER_H_ 6 #define UI_AURA_SHELL_SHADOW_CONTROLLER_H_
7 #pragma once 7 #pragma once
8 8
9 #include <map> 9 #include <map>
10 10
11 #include "base/basictypes.h" 11 #include "base/basictypes.h"
12 #include "base/compiler_specific.h" 12 #include "base/compiler_specific.h"
13 #include "base/memory/linked_ptr.h" 13 #include "base/memory/linked_ptr.h"
14 #include "ui/aura/desktop_observer.h" 14 #include "ui/aura/root_window_observer.h"
15 #include "ui/aura/window_observer.h" 15 #include "ui/aura/window_observer.h"
16 #include "ui/aura_shell/aura_shell_export.h" 16 #include "ui/aura_shell/aura_shell_export.h"
17 17
18 namespace aura { 18 namespace aura {
19 class Window; 19 class Window;
20 } 20 }
21 namespace gfx { 21 namespace gfx {
22 class Rect; 22 class Rect;
23 } 23 }
24 24
25 namespace aura_shell { 25 namespace aura_shell {
26 namespace internal { 26 namespace internal {
27 27
28 class Shadow; 28 class Shadow;
29 29
30 // ShadowController observes changes to windows and creates and updates drop 30 // ShadowController observes changes to windows and creates and updates drop
31 // shadows as needed. 31 // shadows as needed.
32 class AURA_SHELL_EXPORT ShadowController : public aura::DesktopObserver, 32 class AURA_SHELL_EXPORT ShadowController : public aura::RootWindowObserver,
33 public aura::WindowObserver { 33 public aura::WindowObserver {
34 public: 34 public:
35 class TestApi { 35 class TestApi {
36 public: 36 public:
37 explicit TestApi(ShadowController* controller) : controller_(controller) {} 37 explicit TestApi(ShadowController* controller) : controller_(controller) {}
38 ~TestApi() {} 38 ~TestApi() {}
39 39
40 Shadow* GetShadowForWindow(aura::Window* window) { 40 Shadow* GetShadowForWindow(aura::Window* window) {
41 return controller_->GetShadowForWindow(window); 41 return controller_->GetShadowForWindow(window);
42 } 42 }
43 43
44 private: 44 private:
45 ShadowController* controller_; // not owned 45 ShadowController* controller_; // not owned
46 46
47 DISALLOW_COPY_AND_ASSIGN(TestApi); 47 DISALLOW_COPY_AND_ASSIGN(TestApi);
48 }; 48 };
49 49
50 explicit ShadowController(); 50 explicit ShadowController();
51 virtual ~ShadowController(); 51 virtual ~ShadowController();
52 52
53 // aura::DesktopObserver override: 53 // aura::RootWindowObserver override:
54 virtual void OnWindowInitialized(aura::Window* window) OVERRIDE; 54 virtual void OnWindowInitialized(aura::Window* window) OVERRIDE;
55 55
56 // aura::WindowObserver overrides: 56 // aura::WindowObserver overrides:
57 virtual void OnWindowPropertyChanged( 57 virtual void OnWindowPropertyChanged(
58 aura::Window* window, const char* name, void* old) OVERRIDE; 58 aura::Window* window, const char* name, void* old) OVERRIDE;
59 virtual void OnWindowBoundsChanged( 59 virtual void OnWindowBoundsChanged(
60 aura::Window* window, const gfx::Rect& bounds) OVERRIDE; 60 aura::Window* window, const gfx::Rect& bounds) OVERRIDE;
61 virtual void OnWindowDestroyed(aura::Window* window) OVERRIDE; 61 virtual void OnWindowDestroyed(aura::Window* window) OVERRIDE;
62 62
63 private: 63 private:
(...skipping 16 matching lines...) Expand all
80 80
81 WindowShadowMap window_shadows_; 81 WindowShadowMap window_shadows_;
82 82
83 DISALLOW_COPY_AND_ASSIGN(ShadowController); 83 DISALLOW_COPY_AND_ASSIGN(ShadowController);
84 }; 84 };
85 85
86 } // namepsace aura_shell 86 } // namepsace aura_shell
87 } // namepsace internal 87 } // namepsace internal
88 88
89 #endif // UI_AURA_SHELL_SHADOW_CONTROLLER_H_ 89 #endif // UI_AURA_SHELL_SHADOW_CONTROLLER_H_
OLDNEW
« no previous file with comments | « ui/aura_shell/root_window_layout_manager.cc ('k') | ui/aura_shell/shadow_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698