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

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

Issue 9315015: Adds two new observer methods to allow code to be notified when a Window is added/removed from a ... (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 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 void ToggleFullScreen(); 185 void ToggleFullScreen();
186 #endif 186 #endif
187 187
188 // Overridden from Window: 188 // Overridden from Window:
189 virtual RootWindow* GetRootWindow() OVERRIDE; 189 virtual RootWindow* GetRootWindow() OVERRIDE;
190 virtual void SetTransform(const ui::Transform& transform) OVERRIDE; 190 virtual void SetTransform(const ui::Transform& transform) OVERRIDE;
191 191
192 // Overridden from ui::CompositorDelegate: 192 // Overridden from ui::CompositorDelegate:
193 virtual void ScheduleDraw() OVERRIDE; 193 virtual void ScheduleDraw() OVERRIDE;
194 194
195 // Overridden from Window: 195 private:
196 virtual void OnWindowAttachedToRootWindow( 196 friend class Window;
197 Window* window) OVERRIDE;
198 virtual void OnWindowDetachingFromRootWindow(
199 Window* window) OVERRIDE;
200 197
201 private:
202 RootWindow(); 198 RootWindow();
203 virtual ~RootWindow(); 199 virtual ~RootWindow();
204 200
205 // Called whenever the mouse moves, tracks the current |mouse_moved_handler_|, 201 // Called whenever the mouse moves, tracks the current |mouse_moved_handler_|,
206 // sending exited and entered events as its value changes. 202 // sending exited and entered events as its value changes.
207 void HandleMouseMoved(const MouseEvent& event, Window* target); 203 void HandleMouseMoved(const MouseEvent& event, Window* target);
208 204
209 bool ProcessMouseEvent(Window* target, MouseEvent* event); 205 bool ProcessMouseEvent(Window* target, MouseEvent* event);
210 bool ProcessKeyEvent(Window* target, KeyEvent* event); 206 bool ProcessKeyEvent(Window* target, KeyEvent* event);
211 ui::TouchStatus ProcessTouchEvent(Window* target, TouchEvent* event); 207 ui::TouchStatus ProcessTouchEvent(Window* target, TouchEvent* event);
212 ui::GestureStatus ProcessGestureEvent(Window* target, GestureEvent* event); 208 ui::GestureStatus ProcessGestureEvent(Window* target, GestureEvent* event);
213 bool ProcessGestures(GestureRecognizer::Gestures* gestures); 209 bool ProcessGestures(GestureRecognizer::Gestures* gestures);
214 210
211 // Called when a Window is attached or detached from the RootWindow.
212 void OnWindowAddedToRootWindow(Window* window);
213 void OnWindowRemovedFromRootWindow(Window* window);
214
215 // Overridden from Window: 215 // Overridden from Window:
216 virtual bool CanFocus() const OVERRIDE; 216 virtual bool CanFocus() const OVERRIDE;
217 virtual bool CanReceiveEvents() const OVERRIDE; 217 virtual bool CanReceiveEvents() const OVERRIDE;
218 virtual internal::FocusManager* GetFocusManager() OVERRIDE; 218 virtual internal::FocusManager* GetFocusManager() 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;
(...skipping 64 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