Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 CONTENT_BROWSER_COMPOSITOR_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ | 5 #ifndef CONTENT_BROWSER_COMPOSITOR_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ |
| 6 #define CONTENT_BROWSER_COMPOSITOR_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ | 6 #define CONTENT_BROWSER_COMPOSITOR_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ |
| 7 | 7 |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "base/threading/non_thread_safe.h" | 9 #include "base/threading/non_thread_safe.h" |
| 10 #include "build/build_config.h" | 10 #include "build/build_config.h" |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 64 // The argument |params_mac| is used to communicate parameters needed on Mac | 64 // The argument |params_mac| is used to communicate parameters needed on Mac |
| 65 // to display the CALayer for the swap in the browser process. | 65 // to display the CALayer for the swap in the browser process. |
| 66 // TODO(ccameron): Remove |params_mac| when the CALayer tree is hosted in the | 66 // TODO(ccameron): Remove |params_mac| when the CALayer tree is hosted in the |
| 67 // browser process. | 67 // browser process. |
| 68 virtual void OnGpuSwapBuffersCompleted( | 68 virtual void OnGpuSwapBuffersCompleted( |
| 69 const std::vector<ui::LatencyInfo>& latency_info, | 69 const std::vector<ui::LatencyInfo>& latency_info, |
| 70 gfx::SwapResult result, | 70 gfx::SwapResult result, |
| 71 const gpu::GpuProcessHostedCALayerTreeParamsMac* params_mac) = 0; | 71 const gpu::GpuProcessHostedCALayerTreeParamsMac* params_mac) = 0; |
| 72 | 72 |
| 73 #if defined(OS_MACOSX) | 73 #if defined(OS_MACOSX) |
| 74 virtual void SetSurfaceSuspendedForRecycle(bool suspended) = 0; | 74 virtual void SetSurfaceSuspendedForRecycle(bool suspended); |
|
danakj
2016/05/26 21:33:51
why not abstract?
ccameron
2016/05/26 22:46:16
I wanted to get rid of all of the #if defined(OS_M
| |
| 75 #endif | 75 #endif |
| 76 | 76 |
| 77 cc::SyntheticBeginFrameSource* begin_frame_source() { | 77 cc::SyntheticBeginFrameSource* begin_frame_source() { |
| 78 return synthetic_begin_frame_source_.get(); | 78 return synthetic_begin_frame_source_.get(); |
| 79 } | 79 } |
| 80 | 80 |
| 81 protected: | 81 protected: |
| 82 // Constructor used by the accelerated implementation. | 82 // Constructor used by the accelerated implementation. |
| 83 BrowserCompositorOutputSurface( | 83 BrowserCompositorOutputSurface( |
| 84 scoped_refptr<cc::ContextProvider> context, | 84 scoped_refptr<cc::ContextProvider> context, |
| (...skipping 29 matching lines...) Expand all Loading... | |
| 114 | 114 |
| 115 std::unique_ptr<display_compositor::CompositorOverlayCandidateValidator> | 115 std::unique_ptr<display_compositor::CompositorOverlayCandidateValidator> |
| 116 overlay_candidate_validator_; | 116 overlay_candidate_validator_; |
| 117 | 117 |
| 118 DISALLOW_COPY_AND_ASSIGN(BrowserCompositorOutputSurface); | 118 DISALLOW_COPY_AND_ASSIGN(BrowserCompositorOutputSurface); |
| 119 }; | 119 }; |
| 120 | 120 |
| 121 } // namespace content | 121 } // namespace content |
| 122 | 122 |
| 123 #endif // CONTENT_BROWSER_COMPOSITOR_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ | 123 #endif // CONTENT_BROWSER_COMPOSITOR_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ |
| OLD | NEW |