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

Unified Diff: ui/aura/root_window.h

Issue 7976020: Wires up mouse capture code for aura. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix aura build Created 9 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/base.gypi ('k') | ui/aura/root_window.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/root_window.h
diff --git a/ui/aura/root_window.h b/ui/aura/root_window.h
index d709ce3311c1548400f52d56c893329fb5b2c18a..5d3de84a3ccaf53cd4f47da443f75af374c3ceda 100644
--- a/ui/aura/root_window.h
+++ b/ui/aura/root_window.h
@@ -26,12 +26,33 @@ class RootWindow : public Window {
// Handles a key event. Returns true if handled.
bool HandleKeyEvent(const KeyEvent& event);
+ // Sets capture to the specified window.
+ void SetCapture(Window* window);
+
+ // If |window| has mouse capture, the current capture window is set to NULL.
+ void ReleaseCapture(Window* window);
+
+ // Returns the window that has mouse capture.
+ Window* capture_window() { return capture_window_; }
+
+ // Invoked when a child window is destroyed. Cleans up any references to the
+ // Window.
+ void WindowDestroying(Window* window);
+
+ // Current handler for mouse events.
+ Window* mouse_pressed_handler() { return mouse_pressed_handler_; }
+
// Overridden from Window:
virtual FocusManager* GetFocusManager() OVERRIDE;
+ protected:
+ // Overridden from Window:
+ virtual internal::RootWindow* GetRoot() OVERRIDE;
+
private:
Window* mouse_pressed_handler_;
scoped_ptr<FocusManager> focus_manager_;
+ Window* capture_window_;
DISALLOW_COPY_AND_ASSIGN(RootWindow);
};
« no previous file with comments | « base/base.gypi ('k') | ui/aura/root_window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698