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

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

Issue 16189012: Add a path to use CALayers to display content (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Resolve again Created 7 years, 6 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2013 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.
4
5 #ifndef CONTENT_BROWSER_RENDERER_HOST_COMPOSITING_IOSURFACE_LAYER_MAC_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_COMPOSITING_IOSURFACE_LAYER_MAC_H_
7
8 #import <Cocoa/Cocoa.h>
9
10 #include "base/mac/scoped_cftyperef.h"
11 #include "base/memory/ref_counted.h"
12
13 namespace content {
14 class CompositingIOSurfaceContext;
15 class RenderWidgetHostViewMac;
16 }
17
18 // The CoreAnimation layer for drawing accelerated content.
19 @interface CompositingIOSurfaceLayer : CAOpenGLLayer {
20 @private
21 content::RenderWidgetHostViewMac* renderWidgetHostView_;
22 scoped_refptr<content::CompositingIOSurfaceContext> context_;
23 }
24
25 @property(nonatomic, readonly)
26 scoped_refptr<content::CompositingIOSurfaceContext> context;
27
28 - (id)initWithRenderWidgetHostViewMac:(content::RenderWidgetHostViewMac*)r;
29
30 // The OpenGL context may be destroyed periodically (e.g, when moving across
31 // displays). This will re-allocate the context if need be, and returns whether
32 // or not the context now exists.
33 - (BOOL)ensureContext;
34
35 // Update the scale factor of the layer to match the scale factor of the
36 // IOSurface.
37 - (void)updateScaleFactor;
38
39 // Remove this layer from the layer heirarchy, and mark that
40 // |renderWidgetHostView_| is no longer valid and may no longer be dereferenced.
41 - (void)disableCompositing;
42
43 @end
44
45 #endif // CONTENT_BROWSER_RENDERER_HOST_COMPOSITING_IOSURFACE_LAYER_MAC_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/browser_window_controller.mm ('k') | content/browser/renderer_host/compositing_iosurface_layer_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698