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

Side by Side Diff: content/public/test/test_synchronous_compositor_android.cc

Issue 817603002: cc: Make scheduling be driven by vsync for android webview. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Small fix after rebase. Created 5 years, 9 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/public/test/test_synchronous_compositor_android.h" 5 #include "content/public/test/test_synchronous_compositor_android.h"
6 6
7 #include "cc/output/begin_frame_args.h"
7 #include "cc/output/compositor_frame.h" 8 #include "cc/output/compositor_frame.h"
8 9
9 namespace content { 10 namespace content {
10 11
11 TestSynchronousCompositor::TestSynchronousCompositor() 12 TestSynchronousCompositor::TestSynchronousCompositor()
12 : client_(NULL), hardware_initialized_(false) { 13 : client_(NULL), hardware_initialized_(false) {
13 } 14 }
14 15
15 TestSynchronousCompositor::~TestSynchronousCompositor() { 16 TestSynchronousCompositor::~TestSynchronousCompositor() {
16 DCHECK(!hardware_initialized_); 17 DCHECK(!hardware_initialized_);
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 62
62 bool TestSynchronousCompositor::DemandDrawSw(SkCanvas* canvas) { 63 bool TestSynchronousCompositor::DemandDrawSw(SkCanvas* canvas) {
63 DCHECK(canvas); 64 DCHECK(canvas);
64 return true; 65 return true;
65 } 66 }
66 67
67 void TestSynchronousCompositor::SetMemoryPolicy(size_t bytes_limit) { 68 void TestSynchronousCompositor::SetMemoryPolicy(size_t bytes_limit) {
68 DCHECK(!bytes_limit || hardware_initialized_) << bytes_limit; 69 DCHECK(!bytes_limit || hardware_initialized_) << bytes_limit;
69 } 70 }
70 71
72 void TestSynchronousCompositor::SendBeginFrame(cc::BeginFrameArgs args) {
73 client_->PostInvalidate();
74 }
75
71 } // namespace content 76 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698