Move VISUAL_STATE promise to activation
[chromium-blink-merge.git] / ui / ozone / platform / cast / surface_ozone_egl_cast.h
blob197ef0b697c8acd5e31516ceb32ad1fd3fcdcd95
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef UI_OZONE_PLATFORM_CAST_SURFACE_OZONE_EGL_CAST_H_
6 #define UI_OZONE_PLATFORM_CAST_SURFACE_OZONE_EGL_CAST_H_
8 #include "ui/ozone/public/surface_ozone_egl.h"
10 namespace ui {
12 class SurfaceFactoryCast;
14 // EGL surface wrapper for OzonePlatformCast.
15 class SurfaceOzoneEglCast : public SurfaceOzoneEGL {
16 public:
17 explicit SurfaceOzoneEglCast(SurfaceFactoryCast* parent) : parent_(parent) {}
18 ~SurfaceOzoneEglCast() override;
20 // SurfaceOzoneEGL implementation:
21 intptr_t GetNativeWindow() override;
22 bool OnSwapBuffers() override;
23 bool OnSwapBuffersAsync(const SwapCompletionCallback& callback) override;
24 bool ResizeNativeWindow(const gfx::Size& viewport_size) override;
25 scoped_ptr<gfx::VSyncProvider> CreateVSyncProvider() override;
27 private:
28 SurfaceFactoryCast* parent_;
30 DISALLOW_COPY_AND_ASSIGN(SurfaceOzoneEglCast);
33 } // namespace ui
35 #endif // UI_OZONE_PLATFORM_CAST_SURFACE_OZONE_EGL_CAST_H_