OLD | NEW |
---|---|
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 COMPONENTS_MUS_WS_SERVER_WINDOW_TRACKER_H_ | 5 #ifndef COMPONENTS_MUS_WS_FRAME_GENERATOR_DELEGATE_H_ |
6 #define COMPONENTS_MUS_WS_SERVER_WINDOW_TRACKER_H_ | 6 #define COMPONENTS_MUS_WS_FRAME_GENERATOR_DELEGATE_H_ |
7 | |
8 #include <stdint.h> | |
9 #include <set> | |
10 | 7 |
11 #include "base/macros.h" | 8 #include "base/macros.h" |
12 #include "components/mus/ws/server_window.h" | |
13 #include "components/mus/ws/server_window_observer.h" | |
14 #include "ui/base/window_tracker_template.h" | |
15 | 9 |
16 namespace mus { | 10 namespace mus { |
17 namespace ws { | 11 namespace ws { |
18 | 12 |
19 using ServerWindowTracker = | 13 class ServerWindow; |
20 ui::WindowTrackerTemplate<ServerWindow, ServerWindowObserver>; | 14 |
15 struct ViewportMetrics { | |
16 gfx::Size size_in_pixels; | |
17 float device_scale_factor = 0.f; | |
18 }; | |
19 | |
20 class FrameGeneratorDelegate { | |
21 public: | |
22 virtual ~FrameGeneratorDelegate(){}; | |
sky
2016/06/30 23:40:20
nit: no ';', space after '()' and move to protecte
mfomitchev
2016/07/06 15:53:09
Done.
| |
23 | |
24 // Returns the root window of the display. | |
25 virtual ServerWindow* GetRootWindow() = 0; | |
26 | |
27 // Called when a compositor frame is finished drawing. | |
28 virtual void OnCompositorFrameDrawn() = 0; | |
29 | |
30 virtual const ViewportMetrics& GetViewportMetrics() = 0; | |
31 }; | |
21 | 32 |
22 } // namespace ws | 33 } // namespace ws |
23 } // namespace mus | 34 } // namespace mus |
24 | 35 |
25 #endif // COMPONENTS_MUS_WS_SERVER_WINDOW_TRACKER_H_ | 36 #endif // COMPONENTS_MUS_WS_FRAME_GENERATOR_DELEGATE_H_ |
OLD | NEW |