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_RENDERER_HOST_BROWSER_COMPOSITOR_VIEW_MAC_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_BROWSER_COMPOSITOR_VIEW_MAC_H_ |
6 #define CONTENT_BROWSER_RENDERER_HOST_BROWSER_COMPOSITOR_VIEW_MAC_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_BROWSER_COMPOSITOR_VIEW_MAC_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
50 ui::Layer* GetRootLayer(); | 50 ui::Layer* GetRootLayer(); |
51 DelegatedFrameHost* GetDelegatedFrameHost(); | 51 DelegatedFrameHost* GetDelegatedFrameHost(); |
52 | 52 |
53 // This may return nullptr, if this has detached itself from its | 53 // This may return nullptr, if this has detached itself from its |
54 // ui::Compositor. | 54 // ui::Compositor. |
55 ui::AcceleratedWidgetMac* GetAcceleratedWidgetMac(); | 55 ui::AcceleratedWidgetMac* GetAcceleratedWidgetMac(); |
56 | 56 |
57 void SwapCompositorFrame(uint32_t output_surface_id, | 57 void SwapCompositorFrame(uint32_t output_surface_id, |
58 cc::CompositorFrame frame); | 58 cc::CompositorFrame frame); |
59 void SetHasTransparentBackground(bool transparent); | 59 void SetHasTransparentBackground(bool transparent); |
| 60 void SetDisplayColorSpace(const gfx::ColorSpace& color_space); |
60 void UpdateVSyncParameters(const base::TimeTicks& timebase, | 61 void UpdateVSyncParameters(const base::TimeTicks& timebase, |
61 const base::TimeDelta& interval); | 62 const base::TimeDelta& interval); |
62 | 63 |
63 // This is used to ensure that the ui::Compositor be attached to the | 64 // This is used to ensure that the ui::Compositor be attached to the |
64 // DelegatedFrameHost while the RWHImpl is visible. | 65 // DelegatedFrameHost while the RWHImpl is visible. |
65 // Note: This should be called before the RWHImpl is made visible and after | 66 // Note: This should be called before the RWHImpl is made visible and after |
66 // it has been hidden, in order to ensure that thumbnailer notifications to | 67 // it has been hidden, in order to ensure that thumbnailer notifications to |
67 // initiate copies occur before the ui::Compositor be detached. | 68 // initiate copies occur before the ui::Compositor be detached. |
68 void SetRenderWidgetHostIsHidden(bool hidden); | 69 void SetRenderWidgetHostIsHidden(bool hidden); |
69 | 70 |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
147 bool has_transparent_background_ = false; | 148 bool has_transparent_background_ = false; |
148 | 149 |
149 bool has_been_destroyed_ = false; | 150 bool has_been_destroyed_ = false; |
150 | 151 |
151 base::WeakPtrFactory<BrowserCompositorMac> weak_factory_; | 152 base::WeakPtrFactory<BrowserCompositorMac> weak_factory_; |
152 }; | 153 }; |
153 | 154 |
154 } // namespace content | 155 } // namespace content |
155 | 156 |
156 #endif // CONTENT_BROWSER_RENDERER_HOST_BROWSER_COMPOSITOR_VIEW_MAC_H_ | 157 #endif // CONTENT_BROWSER_RENDERER_HOST_BROWSER_COMPOSITOR_VIEW_MAC_H_ |
OLD | NEW |