OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_GPU_GPU_SURFACE_TRACKER_H_ | 5 #ifndef CONTENT_BROWSER_GPU_GPU_SURFACE_TRACKER_H_ |
6 #define CONTENT_BROWSER_GPU_GPU_SURFACE_TRACKER_H_ | 6 #define CONTENT_BROWSER_GPU_GPU_SURFACE_TRACKER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 const scoped_refptr<SurfaceRef>& surface_ref); | 115 const scoped_refptr<SurfaceRef>& surface_ref); |
116 ~SurfaceInfo(); | 116 ~SurfaceInfo(); |
117 int renderer_id; | 117 int renderer_id; |
118 int render_widget_id; | 118 int render_widget_id; |
119 gfx::AcceleratedWidget native_widget; | 119 gfx::AcceleratedWidget native_widget; |
120 gfx::GLSurfaceHandle handle; | 120 gfx::GLSurfaceHandle handle; |
121 scoped_refptr<SurfaceRef> surface_ref; | 121 scoped_refptr<SurfaceRef> surface_ref; |
122 }; | 122 }; |
123 typedef std::map<int, SurfaceInfo> SurfaceMap; | 123 typedef std::map<int, SurfaceInfo> SurfaceMap; |
124 | 124 |
125 friend struct DefaultSingletonTraits<GpuSurfaceTracker>; | 125 friend struct base::DefaultSingletonTraits<GpuSurfaceTracker>; |
126 | 126 |
127 GpuSurfaceTracker(); | 127 GpuSurfaceTracker(); |
128 ~GpuSurfaceTracker() override; | 128 ~GpuSurfaceTracker() override; |
129 | 129 |
130 base::Lock lock_; | 130 base::Lock lock_; |
131 SurfaceMap surface_map_; | 131 SurfaceMap surface_map_; |
132 int next_surface_id_; | 132 int next_surface_id_; |
133 | 133 |
134 DISALLOW_COPY_AND_ASSIGN(GpuSurfaceTracker); | 134 DISALLOW_COPY_AND_ASSIGN(GpuSurfaceTracker); |
135 }; | 135 }; |
136 | 136 |
137 } // namespace content | 137 } // namespace content |
138 | 138 |
139 #endif // CONTENT_BROWSER_GPU_GPU_SURFACE_TRACKER_H_ | 139 #endif // CONTENT_BROWSER_GPU_GPU_SURFACE_TRACKER_H_ |
OLD | NEW |