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

Side by Side Diff: ui/aura/window_tree_host.h

Issue 2556803002: Making WTH::InitCompositor() protected instead of public. (Closed)
Patch Set: Calling InitHost() instead of InitCompositor() in a couple of places. Created 4 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
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_AURA_WINDOW_TREE_HOST_H_ 5 #ifndef UI_AURA_WINDOW_TREE_HOST_H_
6 #define UI_AURA_WINDOW_TREE_HOST_H_ 6 #define UI_AURA_WINDOW_TREE_HOST_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 53
54 // Creates a new WindowTreeHost. The caller owns the returned value. 54 // Creates a new WindowTreeHost. The caller owns the returned value.
55 static WindowTreeHost* Create(const gfx::Rect& bounds_in_pixels); 55 static WindowTreeHost* Create(const gfx::Rect& bounds_in_pixels);
56 56
57 // Returns the WindowTreeHost for the specified accelerated widget, or NULL 57 // Returns the WindowTreeHost for the specified accelerated widget, or NULL
58 // if there is none associated. 58 // if there is none associated.
59 static WindowTreeHost* GetForAcceleratedWidget(gfx::AcceleratedWidget widget); 59 static WindowTreeHost* GetForAcceleratedWidget(gfx::AcceleratedWidget widget);
60 60
61 void InitHost(); 61 void InitHost();
62 62
63 void InitCompositor();
64
65 void AddObserver(WindowTreeHostObserver* observer); 63 void AddObserver(WindowTreeHostObserver* observer);
66 void RemoveObserver(WindowTreeHostObserver* observer); 64 void RemoveObserver(WindowTreeHostObserver* observer);
67 65
68 Window* window() { return window_; } 66 Window* window() { return window_; }
69 const Window* window() const { return window_; } 67 const Window* window() const { return window_; }
70 68
71 ui::EventProcessor* event_processor(); 69 ui::EventProcessor* event_processor();
72 70
73 WindowEventDispatcher* dispatcher() { 71 WindowEventDispatcher* dispatcher() {
74 return const_cast<WindowEventDispatcher*>( 72 return const_cast<WindowEventDispatcher*>(
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 protected: 184 protected:
187 friend class TestScreen; // TODO(beng): see if we can remove/consolidate. 185 friend class TestScreen; // TODO(beng): see if we can remove/consolidate.
188 186
189 WindowTreeHost(); 187 WindowTreeHost();
190 explicit WindowTreeHost(std::unique_ptr<WindowPort> window_port); 188 explicit WindowTreeHost(std::unique_ptr<WindowPort> window_port);
191 189
192 void DestroyCompositor(); 190 void DestroyCompositor();
193 void DestroyDispatcher(); 191 void DestroyDispatcher();
194 192
195 void CreateCompositor(); 193 void CreateCompositor();
194 void InitCompositor();
196 void OnAcceleratedWidgetAvailable(); 195 void OnAcceleratedWidgetAvailable();
197 196
198 // Returns the location of the RootWindow on native screen. 197 // Returns the location of the RootWindow on native screen.
199 virtual gfx::Point GetLocationOnScreenInPixels() const = 0; 198 virtual gfx::Point GetLocationOnScreenInPixels() const = 0;
200 199
201 void OnHostMovedInPixels(const gfx::Point& new_location_in_pixels); 200 void OnHostMovedInPixels(const gfx::Point& new_location_in_pixels);
202 void OnHostResizedInPixels(const gfx::Size& new_size_in_pixels); 201 void OnHostResizedInPixels(const gfx::Size& new_size_in_pixels);
203 void OnHostWorkspaceChanged(); 202 void OnHostWorkspaceChanged();
204 void OnHostCloseRequested(); 203 void OnHostCloseRequested();
205 void OnHostActivated(); 204 void OnHostActivated();
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 bool owned_input_method_; 260 bool owned_input_method_;
262 261
263 gfx::Insets output_surface_padding_in_pixels_; 262 gfx::Insets output_surface_padding_in_pixels_;
264 263
265 DISALLOW_COPY_AND_ASSIGN(WindowTreeHost); 264 DISALLOW_COPY_AND_ASSIGN(WindowTreeHost);
266 }; 265 };
267 266
268 } // namespace aura 267 } // namespace aura
269 268
270 #endif // UI_AURA_WINDOW_TREE_HOST_H_ 269 #endif // UI_AURA_WINDOW_TREE_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698