| Index: services/ui/ws/frame_generator_delegate.h
|
| diff --git a/services/ui/ws/user_id_tracker_observer.h b/services/ui/ws/frame_generator_delegate.h
|
| similarity index 30%
|
| copy from services/ui/ws/user_id_tracker_observer.h
|
| copy to services/ui/ws/frame_generator_delegate.h
|
| index 23d5eae02b77a03c11760e80152534d8b7441511..456bab2e106dc9ff684e1a875a75d8d7b5b15a7d 100644
|
| --- a/services/ui/ws/user_id_tracker_observer.h
|
| +++ b/services/ui/ws/frame_generator_delegate.h
|
| @@ -2,28 +2,36 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| -#ifndef SERVICES_UI_WS_USER_ID_TRACKER_OBSERVER_H_
|
| -#define SERVICES_UI_WS_USER_ID_TRACKER_OBSERVER_H_
|
| +#ifndef SERVICES_UI_WS_FRAME_GENERATOR_DELEGATE_H_
|
| +#define SERVICES_UI_WS_FRAME_GENERATOR_DELEGATE_H_
|
|
|
| -#include <stdint.h>
|
| -
|
| -#include "services/ui/ws/user_id.h"
|
| +#include "base/macros.h"
|
|
|
| namespace ui {
|
| namespace ws {
|
|
|
| -class UserIdTrackerObserver {
|
| +class ServerWindow;
|
| +
|
| +struct ViewportMetrics {
|
| + gfx::Size size_in_pixels;
|
| + float device_scale_factor = 0.f;
|
| +};
|
| +
|
| +class FrameGeneratorDelegate {
|
| public:
|
| - virtual void OnActiveUserIdChanged(const UserId& previously_active_id,
|
| - const UserId& active_id) {}
|
| - virtual void OnUserIdAdded(const UserId& id) {}
|
| - virtual void OnUserIdRemoved(const UserId& id) {}
|
| + // 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;
|
|
|
| protected:
|
| - virtual ~UserIdTrackerObserver() {}
|
| + virtual ~FrameGeneratorDelegate() {}
|
| };
|
|
|
| } // namespace ws
|
| } // namespace ui
|
|
|
| -#endif // SERVICES_UI_WS_USER_ID_TRACKER_OBSERVER_H_
|
| +#endif // SERVICES_UI_WS_FRAME_GENERATOR_DELEGATE_H_
|
|
|