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

Side by Side Diff: ui/aura/client/capture_client.h

Issue 38423002: Make aura::clients take Window instead of RootWindow (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 7 years, 1 month 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/client/activation_client.cc ('k') | ui/aura/client/capture_client.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_CLIENT_CAPTURE_CLIENT_H_ 5 #ifndef UI_AURA_CLIENT_CAPTURE_CLIENT_H_
6 #define UI_AURA_CLIENT_CAPTURE_CLIENT_H_ 6 #define UI_AURA_CLIENT_CAPTURE_CLIENT_H_
7 7
8 #include "ui/aura/aura_export.h" 8 #include "ui/aura/aura_export.h"
9 9
10 namespace aura { 10 namespace aura {
11 class RootWindow;
12 class Window; 11 class Window;
13 12
14 namespace client { 13 namespace client {
15 14
16 // An interface implemented by an object that manages input capture. 15 // An interface implemented by an object that manages input capture.
17 class AURA_EXPORT CaptureClient { 16 class AURA_EXPORT CaptureClient {
18 public: 17 public:
19 // Does a capture on the |window|. 18 // Does a capture on the |window|.
20 virtual void SetCapture(Window* window) = 0; 19 virtual void SetCapture(Window* window) = 0;
21 20
22 // Releases a capture from the |window|. 21 // Releases a capture from the |window|.
23 virtual void ReleaseCapture(Window* window) = 0; 22 virtual void ReleaseCapture(Window* window) = 0;
24 23
25 // Returns the current capture window. 24 // Returns the current capture window.
26 virtual Window* GetCaptureWindow() = 0; 25 virtual Window* GetCaptureWindow() = 0;
27 26
28 protected: 27 protected:
29 virtual ~CaptureClient() {} 28 virtual ~CaptureClient() {}
30 }; 29 };
31 30
32 // Sets/Gets the capture client on the RootWindow. 31 // Sets/Gets the capture client on the root Window.
33 AURA_EXPORT void SetCaptureClient(RootWindow* root_window, 32 AURA_EXPORT void SetCaptureClient(Window* root_window,
34 CaptureClient* client); 33 CaptureClient* client);
35 AURA_EXPORT CaptureClient* GetCaptureClient(RootWindow* root_window); 34 AURA_EXPORT CaptureClient* GetCaptureClient(Window* root_window);
36 35
37 // A utility function to get the current capture window. Returns NULL 36 // A utility function to get the current capture window. Returns NULL
38 // if the window doesn't have a root window, or there is no capture window. 37 // if the window doesn't have a root window, or there is no capture window.
39 AURA_EXPORT Window* GetCaptureWindow(Window* window); 38 AURA_EXPORT Window* GetCaptureWindow(Window* window);
40 39
41 } // namespace clients 40 } // namespace clients
42 } // namespace aura 41 } // namespace aura
43 42
44 #endif // UI_AURA_CLIENT_CAPTURE_CLIENT_H_ 43 #endif // UI_AURA_CLIENT_CAPTURE_CLIENT_H_
OLDNEW
« no previous file with comments | « ui/aura/client/activation_client.cc ('k') | ui/aura/client/capture_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698