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

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

Issue 9318002: Makes GetRootWindow() public on Window so we can begin to convert uses of RootWindow::GetInstance(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | ui/aura/root_window.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_AURA_ROOT_WINDOW_H_ 5 #ifndef UI_AURA_ROOT_WINDOW_H_
6 #define UI_AURA_ROOT_WINDOW_H_ 6 #define UI_AURA_ROOT_WINDOW_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 // whether the queued event was processed by the window or not. 173 // whether the queued event was processed by the window or not.
174 void AdvanceQueuedTouchEvent(Window* window, bool processed); 174 void AdvanceQueuedTouchEvent(Window* window, bool processed);
175 175
176 GestureRecognizer* gesture_recognizer() const { 176 GestureRecognizer* gesture_recognizer() const {
177 return gesture_recognizer_.get(); 177 return gesture_recognizer_.get();
178 } 178 }
179 179
180 // Provided only for testing: 180 // Provided only for testing:
181 void SetGestureRecognizerForTesting(GestureRecognizer* gr); 181 void SetGestureRecognizerForTesting(GestureRecognizer* gr);
182 182
183 // Overridden from Window:
184 virtual void SetTransform(const ui::Transform& transform) OVERRIDE;
185
186 #if !defined(NDEBUG) 183 #if !defined(NDEBUG)
187 // Toggles the host's full screen state. 184 // Toggles the host's full screen state.
188 void ToggleFullScreen(); 185 void ToggleFullScreen();
189 #endif 186 #endif
190 187
188 // Overridden from Window:
189 virtual RootWindow* GetRootWindow() OVERRIDE;
190 virtual void SetTransform(const ui::Transform& transform) OVERRIDE;
191
191 // Overridden from ui::CompositorDelegate: 192 // Overridden from ui::CompositorDelegate:
192 virtual void ScheduleDraw() OVERRIDE; 193 virtual void ScheduleDraw() OVERRIDE;
193 194
194 // Overridden from Window: 195 // Overridden from Window:
195 virtual void OnWindowAttachedToRootWindow( 196 virtual void OnWindowAttachedToRootWindow(
196 Window* window) OVERRIDE; 197 Window* window) OVERRIDE;
197 virtual void OnWindowDetachingFromRootWindow( 198 virtual void OnWindowDetachingFromRootWindow(
198 Window* window) OVERRIDE; 199 Window* window) OVERRIDE;
199 200
200 private: 201 private:
201 RootWindow(); 202 RootWindow();
202 virtual ~RootWindow(); 203 virtual ~RootWindow();
203 204
204 // Called whenever the mouse moves, tracks the current |mouse_moved_handler_|, 205 // Called whenever the mouse moves, tracks the current |mouse_moved_handler_|,
205 // sending exited and entered events as its value changes. 206 // sending exited and entered events as its value changes.
206 void HandleMouseMoved(const MouseEvent& event, Window* target); 207 void HandleMouseMoved(const MouseEvent& event, Window* target);
207 208
208 bool ProcessMouseEvent(Window* target, MouseEvent* event); 209 bool ProcessMouseEvent(Window* target, MouseEvent* event);
209 bool ProcessKeyEvent(Window* target, KeyEvent* event); 210 bool ProcessKeyEvent(Window* target, KeyEvent* event);
210 ui::TouchStatus ProcessTouchEvent(Window* target, TouchEvent* event); 211 ui::TouchStatus ProcessTouchEvent(Window* target, TouchEvent* event);
211 ui::GestureStatus ProcessGestureEvent(Window* target, GestureEvent* event); 212 ui::GestureStatus ProcessGestureEvent(Window* target, GestureEvent* event);
212 bool ProcessGestures(GestureRecognizer::Gestures* gestures); 213 bool ProcessGestures(GestureRecognizer::Gestures* gestures);
213 214
214 // Overridden from Window: 215 // Overridden from Window:
215 virtual bool CanFocus() const OVERRIDE; 216 virtual bool CanFocus() const OVERRIDE;
216 virtual bool CanReceiveEvents() const OVERRIDE; 217 virtual bool CanReceiveEvents() const OVERRIDE;
217 virtual internal::FocusManager* GetFocusManager() OVERRIDE; 218 virtual internal::FocusManager* GetFocusManager() OVERRIDE;
218 virtual RootWindow* GetRootWindow() OVERRIDE;
219 219
220 // Overridden from ui::LayerAnimationObserver: 220 // Overridden from ui::LayerAnimationObserver:
221 virtual void OnLayerAnimationEnded( 221 virtual void OnLayerAnimationEnded(
222 const ui::LayerAnimationSequence* animation) OVERRIDE; 222 const ui::LayerAnimationSequence* animation) OVERRIDE;
223 virtual void OnLayerAnimationScheduled( 223 virtual void OnLayerAnimationScheduled(
224 const ui::LayerAnimationSequence* animation) OVERRIDE; 224 const ui::LayerAnimationSequence* animation) OVERRIDE;
225 virtual void OnLayerAnimationAborted( 225 virtual void OnLayerAnimationAborted(
226 const ui::LayerAnimationSequence* animation) OVERRIDE; 226 const ui::LayerAnimationSequence* animation) OVERRIDE;
227 227
228 // Overridden from FocusManager: 228 // Overridden from FocusManager:
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
289 scoped_ptr<GestureRecognizer> gesture_recognizer_; 289 scoped_ptr<GestureRecognizer> gesture_recognizer_;
290 290
291 bool synthesize_mouse_move_; 291 bool synthesize_mouse_move_;
292 292
293 DISALLOW_COPY_AND_ASSIGN(RootWindow); 293 DISALLOW_COPY_AND_ASSIGN(RootWindow);
294 }; 294 };
295 295
296 } // namespace aura 296 } // namespace aura
297 297
298 #endif // UI_AURA_ROOT_WINDOW_H_ 298 #endif // UI_AURA_ROOT_WINDOW_H_
OLDNEW
« no previous file with comments | « no previous file | ui/aura/root_window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698