OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 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 | 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 SERVICES_SURFACES_DISPLAY_IMPL_H_ | 5 #ifndef SERVICES_SURFACES_DISPLAY_IMPL_H_ |
6 #define SERVICES_SURFACES_DISPLAY_IMPL_H_ | 6 #define SERVICES_SURFACES_DISPLAY_IMPL_H_ |
7 | 7 |
8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
9 #include "cc/surfaces/display_client.h" | 9 #include "cc/surfaces/display_client.h" |
10 #include "cc/surfaces/surface_factory.h" | 10 #include "cc/surfaces/surface_factory.h" |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 void DisplayDamaged() override; | 44 void DisplayDamaged() override; |
45 void DidSwapBuffers() override; | 45 void DidSwapBuffers() override; |
46 void DidSwapBuffersComplete() override; | 46 void DidSwapBuffersComplete() override; |
47 void CommitVSyncParameters(base::TimeTicks timebase, | 47 void CommitVSyncParameters(base::TimeTicks timebase, |
48 base::TimeDelta interval) override; | 48 base::TimeDelta interval) override; |
49 void OutputSurfaceLost() override; | 49 void OutputSurfaceLost() override; |
50 | 50 |
51 // ViewportParameterListener | 51 // ViewportParameterListener |
52 void OnVSyncParametersUpdated(int64_t timebase, int64_t interval) override; | 52 void OnVSyncParametersUpdated(int64_t timebase, int64_t interval) override; |
53 | 53 |
| 54 // Callback for ContextProvider::NotifyOnViewport |
| 55 void OnViewportCreated(); |
| 56 |
54 // SurfaceFactoryClient implementation. | 57 // SurfaceFactoryClient implementation. |
55 void ReturnResources(const cc::ReturnedResourceArray& resources) override; | 58 void ReturnResources(const cc::ReturnedResourceArray& resources) override; |
56 | 59 |
57 void Draw(); | 60 void Draw(); |
58 | 61 |
59 cc::SurfaceManager* manager_; | 62 cc::SurfaceManager* manager_; |
60 cc::SurfaceFactory factory_; | 63 cc::SurfaceFactory factory_; |
61 cc::SurfaceId cc_id_; | 64 cc::SurfaceId cc_id_; |
62 SurfacesScheduler* scheduler_; | 65 SurfacesScheduler* scheduler_; |
63 mojo::ContextProviderPtr context_provider_; | 66 mojo::ContextProviderPtr context_provider_; |
64 mojo::ResourceReturnerPtr returner_; | 67 mojo::ResourceReturnerPtr returner_; |
65 | 68 |
66 gfx::Size last_submitted_frame_size_; | 69 gfx::Size last_submitted_frame_size_; |
67 mojo::FramePtr pending_frame_; | 70 mojo::FramePtr pending_frame_; |
68 SubmitFrameCallback pending_callback_; | 71 SubmitFrameCallback pending_callback_; |
69 | 72 |
70 scoped_ptr<cc::Display> display_; | 73 scoped_ptr<cc::Display> display_; |
71 | 74 |
72 mojo::Binding<mojo::ViewportParameterListener> viewport_param_binding_; | 75 mojo::Binding<mojo::ViewportParameterListener> viewport_param_binding_; |
73 mojo::StrongBinding<mojo::Display> display_binding_; | 76 mojo::StrongBinding<mojo::Display> display_binding_; |
74 | 77 |
75 DISALLOW_COPY_AND_ASSIGN(DisplayImpl); | 78 DISALLOW_COPY_AND_ASSIGN(DisplayImpl); |
76 }; | 79 }; |
77 | 80 |
78 } // namespace surfaces | 81 } // namespace surfaces |
79 | 82 |
80 #endif // SERVICES_SURFACES_DISPLAY_IMPL_H_ | 83 #endif // SERVICES_SURFACES_DISPLAY_IMPL_H_ |
OLD | NEW |