forked from Pissandshittium/pissandshittium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcast_window_manager_aura.h
58 lines (42 loc) · 1.71 KB
/
cast_window_manager_aura.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// Copyright 2017 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROMECAST_GRAPHICS_CAST_WINDOW_MANAGER_AURA_H_
#define CHROMECAST_GRAPHICS_CAST_WINDOW_MANAGER_AURA_H_
#include <memory>
#include "base/macros.h"
#include "chromecast/graphics/cast_window_manager.h"
#include "ui/aura/client/window_parenting_client.h"
namespace aura {
namespace client {
class DefaultCaptureClient;
} // namespace client
} // namespace aura
namespace chromecast {
class CastFocusClientAura;
class CastWindowTreeHost;
class CastWindowManagerAura : public CastWindowManager,
public aura::client::WindowParentingClient {
public:
~CastWindowManagerAura() override;
// CastWindowManager implementation:
void TearDown() override;
void AddWindow(gfx::NativeView window) override;
gfx::NativeView GetRootWindow() override;
void SetWindowId(gfx::NativeView window, WindowId window_id) override;
// aura::client::WindowParentingClient implementation:
aura::Window* GetDefaultParent(aura::Window* window,
const gfx::Rect& bounds) override;
private:
friend class CastWindowManager;
// This class should only be instantiated by CastWindowManager::Create.
explicit CastWindowManagerAura(bool enable_input);
void Setup();
const bool enable_input_;
std::unique_ptr<CastWindowTreeHost> window_tree_host_;
std::unique_ptr<aura::client::DefaultCaptureClient> capture_client_;
std::unique_ptr<CastFocusClientAura> focus_client_;
DISALLOW_COPY_AND_ASSIGN(CastWindowManagerAura);
};
} // namespace chromecast
#endif // CHROMECAST_GRAPHICS_CAST_WINDOW_MANAGER_AURA_H_