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

Side by Side Diff: content/browser/compositor/software_browser_compositor_output_surface.cc

Issue 1545243002: Convert Pass()→std::move() in //content/browser (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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 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 #include "content/browser/compositor/software_browser_compositor_output_surface. h" 5 #include "content/browser/compositor/software_browser_compositor_output_surface. h"
6 6
7 #include <utility>
8
7 #include "base/location.h" 9 #include "base/location.h"
8 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
9 #include "base/single_thread_task_runner.h" 11 #include "base/single_thread_task_runner.h"
10 #include "base/thread_task_runner_handle.h" 12 #include "base/thread_task_runner_handle.h"
11 #include "base/time/time.h" 13 #include "base/time/time.h"
12 #include "build/build_config.h" 14 #include "build/build_config.h"
13 #include "cc/output/compositor_frame.h" 15 #include "cc/output/compositor_frame.h"
14 #include "cc/output/output_surface_client.h" 16 #include "cc/output/output_surface_client.h"
15 #include "cc/output/software_output_device.h" 17 #include "cc/output/software_output_device.h"
16 #include "content/browser/renderer_host/render_widget_host_impl.h" 18 #include "content/browser/renderer_host/render_widget_host_impl.h"
17 #include "ui/events/latency_info.h" 19 #include "ui/events/latency_info.h"
18 #include "ui/gfx/vsync_provider.h" 20 #include "ui/gfx/vsync_provider.h"
19 21
20 namespace content { 22 namespace content {
21 23
22 SoftwareBrowserCompositorOutputSurface::SoftwareBrowserCompositorOutputSurface( 24 SoftwareBrowserCompositorOutputSurface::SoftwareBrowserCompositorOutputSurface(
23 scoped_ptr<cc::SoftwareOutputDevice> software_device, 25 scoped_ptr<cc::SoftwareOutputDevice> software_device,
24 const scoped_refptr<ui::CompositorVSyncManager>& vsync_manager) 26 const scoped_refptr<ui::CompositorVSyncManager>& vsync_manager)
25 : BrowserCompositorOutputSurface(software_device.Pass(), 27 : BrowserCompositorOutputSurface(std::move(software_device), vsync_manager),
26 vsync_manager), 28 weak_factory_(this) {}
27 weak_factory_(this) {
28 }
29 29
30 SoftwareBrowserCompositorOutputSurface:: 30 SoftwareBrowserCompositorOutputSurface::
31 ~SoftwareBrowserCompositorOutputSurface() { 31 ~SoftwareBrowserCompositorOutputSurface() {
32 } 32 }
33 33
34 void SoftwareBrowserCompositorOutputSurface::SwapBuffers( 34 void SoftwareBrowserCompositorOutputSurface::SwapBuffers(
35 cc::CompositorFrame* frame) { 35 cc::CompositorFrame* frame) {
36 base::TimeTicks swap_time = base::TimeTicks::Now(); 36 base::TimeTicks swap_time = base::TimeTicks::Now();
37 for (auto& latency : frame->metadata.latency_info) { 37 for (auto& latency : frame->metadata.latency_info) {
38 latency.AddLatencyNumberWithTimestamp( 38 latency.AddLatencyNumberWithTimestamp(
(...skipping 27 matching lines...) Expand all
66 bool suspended) { 66 bool suspended) {
67 } 67 }
68 68
69 bool SoftwareBrowserCompositorOutputSurface:: 69 bool SoftwareBrowserCompositorOutputSurface::
70 SurfaceShouldNotShowFramesAfterSuspendForRecycle() const { 70 SurfaceShouldNotShowFramesAfterSuspendForRecycle() const {
71 return false; 71 return false;
72 } 72 }
73 #endif 73 #endif
74 74
75 } // namespace content 75 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698