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

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

Issue 8968022: Shell related switches -> aura shell switches. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 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 | Annotate | Revision Log
« no previous file with comments | « ui/aura/aura_switches.cc ('k') | ui/aura/client/activation_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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_ACTIVATION_CLIENT_H_ 5 #ifndef UI_AURA_CLIENT_ACTIVATION_CLIENT_H_
6 #define UI_AURA_CLIENT_ACTIVATION_CLIENT_H_ 6 #define UI_AURA_CLIENT_ACTIVATION_CLIENT_H_
7 #pragma once 7 #pragma once
8 8
9 #include "ui/aura/aura_export.h" 9 #include "ui/aura/aura_export.h"
10 10
11 namespace aura { 11 namespace aura {
12 class Window; 12 class Window;
13 namespace client { 13 namespace client {
14 14
15 // A property key to store a client that handles window activation. The type of
16 // the value is |aura::client::ActivationClient*|.
17 AURA_EXPORT extern const char kRootWindowActivationClient[];
18
19 // A property key to store what the client defines as the active window on the
20 // RootWindow. The type of the value is |aura::Window*|.
21 AURA_EXPORT extern const char kRootWindowActiveWindow[];
22
15 // An interface implemented by an object that manages window activation. 23 // An interface implemented by an object that manages window activation.
16 class AURA_EXPORT ActivationClient { 24 class AURA_EXPORT ActivationClient {
17 public: 25 public:
18 // Activates |window|. If |window| is NULL, nothing happens. 26 // Activates |window|. If |window| is NULL, nothing happens.
19 virtual void ActivateWindow(Window* window) = 0; 27 virtual void ActivateWindow(Window* window) = 0;
20 28
21 // Deactivates |window|. What (if anything) is activated next is up to the 29 // Deactivates |window|. What (if anything) is activated next is up to the
22 // client. If |window| is NULL, nothing happens. 30 // client. If |window| is NULL, nothing happens.
23 virtual void DeactivateWindow(Window* window) = 0; 31 virtual void DeactivateWindow(Window* window) = 0;
24 32
25 // Retrieves the active window, or NULL if there is none. 33 // Retrieves the active window, or NULL if there is none.
26 virtual aura::Window* GetActiveWindow() = 0; 34 virtual aura::Window* GetActiveWindow() = 0;
27 35
28 // Returns true if |window| can be focused. To be focusable, |window| must 36 // Returns true if |window| can be focused. To be focusable, |window| must
29 // exist inside an activatable window. 37 // exist inside an activatable window.
30 virtual bool CanFocusWindow(Window* window) const = 0; 38 virtual bool CanFocusWindow(Window* window) const = 0;
31 39
32 protected: 40 protected:
33 virtual ~ActivationClient() {} 41 virtual ~ActivationClient() {}
34 }; 42 };
35 43
36 // Sets/Gets the activation client on the RootWindow. 44 // Sets/Gets the activation client on the RootWindow.
37 AURA_EXPORT void SetActivationClient(ActivationClient* client); 45 AURA_EXPORT void SetActivationClient(ActivationClient* client);
38 AURA_EXPORT ActivationClient* GetActivationClient(); 46 AURA_EXPORT ActivationClient* GetActivationClient();
39 47
40 } // namespace clients 48 } // namespace clients
41 } // namespace aura 49 } // namespace aura
42 50
43 #endif // UI_AURA_CLIENT_ACTIVATION_CLIENT_H_ 51 #endif // UI_AURA_CLIENT_ACTIVATION_CLIENT_H_
OLDNEW
« no previous file with comments | « ui/aura/aura_switches.cc ('k') | ui/aura/client/activation_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698