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

Side by Side Diff: content/common/gpu/image_transport_surface.h

Issue 630853003: Replace OVERRIDE and FINAL with override and final in content/common/[a-s]* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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
OLDNEW
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_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_ 5 #ifndef CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_
6 #define CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_ 6 #define CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 // Takes weak pointers to objects that outlive the helper. 102 // Takes weak pointers to objects that outlive the helper.
103 ImageTransportHelper(ImageTransportSurface* surface, 103 ImageTransportHelper(ImageTransportSurface* surface,
104 GpuChannelManager* manager, 104 GpuChannelManager* manager,
105 GpuCommandBufferStub* stub, 105 GpuCommandBufferStub* stub,
106 gfx::PluginWindowHandle handle); 106 gfx::PluginWindowHandle handle);
107 virtual ~ImageTransportHelper(); 107 virtual ~ImageTransportHelper();
108 108
109 bool Initialize(); 109 bool Initialize();
110 110
111 // IPC::Listener implementation: 111 // IPC::Listener implementation:
112 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; 112 virtual bool OnMessageReceived(const IPC::Message& message) override;
113 113
114 // Helper send functions. Caller fills in the surface specific params 114 // Helper send functions. Caller fills in the surface specific params
115 // like size and surface id. The helper fills in the rest. 115 // like size and surface id. The helper fills in the rest.
116 void SendAcceleratedSurfaceBuffersSwapped( 116 void SendAcceleratedSurfaceBuffersSwapped(
117 GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params params); 117 GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params params);
118 void SendUpdateVSyncParameters( 118 void SendUpdateVSyncParameters(
119 base::TimeTicks timebase, base::TimeDelta interval); 119 base::TimeTicks timebase, base::TimeDelta interval);
120 120
121 void SendLatencyInfo(const std::vector<ui::LatencyInfo>& latency_info); 121 void SendLatencyInfo(const std::vector<ui::LatencyInfo>& latency_info);
122 122
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 // GLSurfaceAdapter, thereby forwarding GLSurface methods through to it. 166 // GLSurfaceAdapter, thereby forwarding GLSurface methods through to it.
167 class PassThroughImageTransportSurface 167 class PassThroughImageTransportSurface
168 : public gfx::GLSurfaceAdapter, 168 : public gfx::GLSurfaceAdapter,
169 public ImageTransportSurface { 169 public ImageTransportSurface {
170 public: 170 public:
171 PassThroughImageTransportSurface(GpuChannelManager* manager, 171 PassThroughImageTransportSurface(GpuChannelManager* manager,
172 GpuCommandBufferStub* stub, 172 GpuCommandBufferStub* stub,
173 gfx::GLSurface* surface); 173 gfx::GLSurface* surface);
174 174
175 // GLSurface implementation. 175 // GLSurface implementation.
176 virtual bool Initialize() OVERRIDE; 176 virtual bool Initialize() override;
177 virtual void Destroy() OVERRIDE; 177 virtual void Destroy() override;
178 virtual bool SwapBuffers() OVERRIDE; 178 virtual bool SwapBuffers() override;
179 virtual bool PostSubBuffer(int x, int y, int width, int height) OVERRIDE; 179 virtual bool PostSubBuffer(int x, int y, int width, int height) override;
180 virtual bool OnMakeCurrent(gfx::GLContext* context) OVERRIDE; 180 virtual bool OnMakeCurrent(gfx::GLContext* context) override;
181 181
182 // ImageTransportSurface implementation. 182 // ImageTransportSurface implementation.
183 virtual void OnBufferPresented( 183 virtual void OnBufferPresented(
184 const AcceleratedSurfaceMsg_BufferPresented_Params& params) OVERRIDE; 184 const AcceleratedSurfaceMsg_BufferPresented_Params& params) override;
185 virtual void OnResize(gfx::Size size, float scale_factor) OVERRIDE; 185 virtual void OnResize(gfx::Size size, float scale_factor) override;
186 virtual gfx::Size GetSize() OVERRIDE; 186 virtual gfx::Size GetSize() override;
187 virtual void SetLatencyInfo( 187 virtual void SetLatencyInfo(
188 const std::vector<ui::LatencyInfo>& latency_info) OVERRIDE; 188 const std::vector<ui::LatencyInfo>& latency_info) override;
189 virtual void WakeUpGpu() OVERRIDE; 189 virtual void WakeUpGpu() override;
190 190
191 protected: 191 protected:
192 virtual ~PassThroughImageTransportSurface(); 192 virtual ~PassThroughImageTransportSurface();
193 193
194 // If updated vsync parameters can be determined, send this information to 194 // If updated vsync parameters can be determined, send this information to
195 // the browser. 195 // the browser.
196 virtual void SendVSyncUpdateIfAvailable(); 196 virtual void SendVSyncUpdateIfAvailable();
197 197
198 ImageTransportHelper* GetHelper() { return helper_.get(); } 198 ImageTransportHelper* GetHelper() { return helper_.get(); }
199 199
200 private: 200 private:
201 scoped_ptr<ImageTransportHelper> helper_; 201 scoped_ptr<ImageTransportHelper> helper_;
202 bool did_set_swap_interval_; 202 bool did_set_swap_interval_;
203 std::vector<ui::LatencyInfo> latency_info_; 203 std::vector<ui::LatencyInfo> latency_info_;
204 204
205 DISALLOW_COPY_AND_ASSIGN(PassThroughImageTransportSurface); 205 DISALLOW_COPY_AND_ASSIGN(PassThroughImageTransportSurface);
206 }; 206 };
207 207
208 } // namespace content 208 } // namespace content
209 209
210 #endif // CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_ 210 #endif // CONTENT_COMMON_GPU_IMAGE_TRANSPORT_SURFACE_H_
OLDNEW
« no previous file with comments | « content/common/gpu/gpu_memory_manager_unittest.cc ('k') | content/common/gpu/image_transport_surface_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698