Index: components/mus/ws/frame_generator_delegate.h |
diff --git a/components/mus/ws/server_window_tracker.h b/components/mus/ws/frame_generator_delegate.h |
similarity index 30% |
copy from components/mus/ws/server_window_tracker.h |
copy to components/mus/ws/frame_generator_delegate.h |
index d3b73f06be11f828d8b6c79914a0001cd7963752..537eb895913edd92b844419f9811b826d93dfdd2 100644 |
--- a/components/mus/ws/server_window_tracker.h |
+++ b/components/mus/ws/frame_generator_delegate.h |
@@ -2,24 +2,35 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#ifndef COMPONENTS_MUS_WS_SERVER_WINDOW_TRACKER_H_ |
-#define COMPONENTS_MUS_WS_SERVER_WINDOW_TRACKER_H_ |
- |
-#include <stdint.h> |
-#include <set> |
+#ifndef COMPONENTS_MUS_WS_FRAME_GENERATOR_DELEGATE_H_ |
+#define COMPONENTS_MUS_WS_FRAME_GENERATOR_DELEGATE_H_ |
#include "base/macros.h" |
-#include "components/mus/ws/server_window.h" |
-#include "components/mus/ws/server_window_observer.h" |
-#include "ui/base/window_tracker_template.h" |
namespace mus { |
namespace ws { |
-using ServerWindowTracker = |
- ui::WindowTrackerTemplate<ServerWindow, ServerWindowObserver>; |
+class ServerWindow; |
+ |
+struct ViewportMetrics { |
+ gfx::Size size_in_pixels; |
+ float device_scale_factor = 0.f; |
+}; |
+ |
+class FrameGeneratorDelegate { |
+ public: |
+ 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.
|
+ |
+ // Returns the root window of the display. |
+ virtual ServerWindow* GetRootWindow() = 0; |
+ |
+ // Called when a compositor frame is finished drawing. |
+ virtual void OnCompositorFrameDrawn() = 0; |
+ |
+ virtual const ViewportMetrics& GetViewportMetrics() = 0; |
+}; |
} // namespace ws |
} // namespace mus |
-#endif // COMPONENTS_MUS_WS_SERVER_WINDOW_TRACKER_H_ |
+#endif // COMPONENTS_MUS_WS_FRAME_GENERATOR_DELEGATE_H_ |