Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(206)

Side by Side Diff: content/browser/renderer_host/delegated_frame_host.h

Issue 1884043002: Use black for resize gutter in tab fullscreen mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | content/browser/renderer_host/delegated_frame_host.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_DELEGATED_FRAME_HOST_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_DELEGATED_FRAME_HOST_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_DELEGATED_FRAME_HOST_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_DELEGATED_FRAME_HOST_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <vector> 10 #include <vector>
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 class RenderWidgetHostImpl; 51 class RenderWidgetHostImpl;
52 class ResizeLock; 52 class ResizeLock;
53 53
54 // The DelegatedFrameHostClient is the interface from the DelegatedFrameHost, 54 // The DelegatedFrameHostClient is the interface from the DelegatedFrameHost,
55 // which manages delegated frames, and the ui::Compositor being used to 55 // which manages delegated frames, and the ui::Compositor being used to
56 // display them. 56 // display them.
57 class CONTENT_EXPORT DelegatedFrameHostClient { 57 class CONTENT_EXPORT DelegatedFrameHostClient {
58 public: 58 public:
59 virtual ui::Layer* DelegatedFrameHostGetLayer() const = 0; 59 virtual ui::Layer* DelegatedFrameHostGetLayer() const = 0;
60 virtual bool DelegatedFrameHostIsVisible() const = 0; 60 virtual bool DelegatedFrameHostIsVisible() const = 0;
61
62 // Returns the color that the resize gutters should be drawn with. Takes the
63 // suggested color from the current page background.
64 virtual SkColor DelegatedFrameHostGetGutterColor(SkColor color) const = 0;
61 virtual gfx::Size DelegatedFrameHostDesiredSizeInDIP() const = 0; 65 virtual gfx::Size DelegatedFrameHostDesiredSizeInDIP() const = 0;
62 66
63 virtual bool DelegatedFrameCanCreateResizeLock() const = 0; 67 virtual bool DelegatedFrameCanCreateResizeLock() const = 0;
64 virtual std::unique_ptr<ResizeLock> DelegatedFrameHostCreateResizeLock( 68 virtual std::unique_ptr<ResizeLock> DelegatedFrameHostCreateResizeLock(
65 bool defer_compositor_lock) = 0; 69 bool defer_compositor_lock) = 0;
66 virtual void DelegatedFrameHostResizeLockWasReleased() = 0; 70 virtual void DelegatedFrameHostResizeLockWasReleased() = 0;
67 71
68 virtual void DelegatedFrameHostSendCompositorSwapAck( 72 virtual void DelegatedFrameHostSendCompositorSwapAck(
69 int output_surface_id, 73 int output_surface_id,
70 const cc::CompositorFrameAck& ack) = 0; 74 const cc::CompositorFrameAck& ack) = 0;
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after
200 204
201 bool ShouldSkipFrame(gfx::Size size_in_dip) const; 205 bool ShouldSkipFrame(gfx::Size size_in_dip) const;
202 206
203 // Lazily grab a resize lock if the aura window size doesn't match the current 207 // Lazily grab a resize lock if the aura window size doesn't match the current
204 // frame size, to give time to the renderer. 208 // frame size, to give time to the renderer.
205 void MaybeCreateResizeLock(); 209 void MaybeCreateResizeLock();
206 210
207 // Checks if the resize lock can be released because we received an new frame. 211 // Checks if the resize lock can be released because we received an new frame.
208 void CheckResizeLock(); 212 void CheckResizeLock();
209 213
214 SkColor GetGutterColor() const;
215
210 // Update the layers for the resize gutters to the right and bottom of the 216 // Update the layers for the resize gutters to the right and bottom of the
211 // surface layer. 217 // surface layer.
212 void UpdateGutters(); 218 void UpdateGutters();
213 219
214 // Called after async thumbnailer task completes. Scales and crops the result 220 // Called after async thumbnailer task completes. Scales and crops the result
215 // of the copy. 221 // of the copy.
216 static void CopyFromCompositingSurfaceHasResultForVideo( 222 static void CopyFromCompositingSurfaceHasResultForVideo(
217 base::WeakPtr<DelegatedFrameHost> rwhva, 223 base::WeakPtr<DelegatedFrameHost> rwhva,
218 scoped_refptr<OwnedMailbox> subscriber_texture, 224 scoped_refptr<OwnedMailbox> subscriber_texture,
219 scoped_refptr<media::VideoFrame> video_frame, 225 scoped_refptr<media::VideoFrame> video_frame,
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
320 // YUV readback pipeline. 326 // YUV readback pipeline.
321 std::unique_ptr<display_compositor::ReadbackYUVInterface> 327 std::unique_ptr<display_compositor::ReadbackYUVInterface>
322 yuv_readback_pipeline_; 328 yuv_readback_pipeline_;
323 329
324 std::unique_ptr<DelegatedFrameEvictor> delegated_frame_evictor_; 330 std::unique_ptr<DelegatedFrameEvictor> delegated_frame_evictor_;
325 }; 331 };
326 332
327 } // namespace content 333 } // namespace content
328 334
329 #endif // CONTENT_BROWSER_RENDERER_HOST_DELEGATED_FRAME_HOST_H_ 335 #endif // CONTENT_BROWSER_RENDERER_HOST_DELEGATED_FRAME_HOST_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/renderer_host/delegated_frame_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698