OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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 "cc/trees/single_thread_proxy.h" | 5 #include "cc/trees/single_thread_proxy.h" |
6 | 6 |
7 #include "base/auto_reset.h" | 7 #include "base/auto_reset.h" |
8 #include "base/debug/trace_event.h" | 8 #include "base/debug/trace_event.h" |
9 #include "cc/base/thread.h" | 9 #include "cc/base/thread.h" |
10 #include "cc/output/context_provider.h" | 10 #include "cc/output/context_provider.h" |
(...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
361 } | 361 } |
362 | 362 |
363 void SingleThreadProxy::ForceSerializeOnSwapBuffers() { | 363 void SingleThreadProxy::ForceSerializeOnSwapBuffers() { |
364 { | 364 { |
365 DebugScopedSetImplThread impl(this); | 365 DebugScopedSetImplThread impl(this); |
366 if (renderer_initialized_) | 366 if (renderer_initialized_) |
367 layer_tree_host_impl_->renderer()->DoNoOp(); | 367 layer_tree_host_impl_->renderer()->DoNoOp(); |
368 } | 368 } |
369 } | 369 } |
370 | 370 |
371 void SingleThreadProxy::OnSwapBuffersCompleteOnImplThread() { NOTREACHED(); } | |
372 | |
373 bool SingleThreadProxy::CommitAndComposite( | 371 bool SingleThreadProxy::CommitAndComposite( |
374 base::TimeTicks frame_begin_time, | 372 base::TimeTicks frame_begin_time, |
375 gfx::Rect device_viewport_damage_rect, | 373 gfx::Rect device_viewport_damage_rect, |
376 LayerTreeHostImpl::FrameData* frame) { | 374 LayerTreeHostImpl::FrameData* frame) { |
377 DCHECK(Proxy::IsMainThread()); | 375 DCHECK(Proxy::IsMainThread()); |
378 | 376 |
379 if (!layer_tree_host_->InitializeRendererIfNeeded()) | 377 if (!layer_tree_host_->InitializeRendererIfNeeded()) |
380 return false; | 378 return false; |
381 | 379 |
382 scoped_refptr<cc::ContextProvider> offscreen_context_provider; | 380 scoped_refptr<cc::ContextProvider> offscreen_context_provider; |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
468 | 466 |
469 bool SingleThreadProxy::CommitPendingForTesting() { return false; } | 467 bool SingleThreadProxy::CommitPendingForTesting() { return false; } |
470 | 468 |
471 skia::RefPtr<SkPicture> SingleThreadProxy::CapturePicture() { | 469 skia::RefPtr<SkPicture> SingleThreadProxy::CapturePicture() { |
472 // Impl-side painting only. | 470 // Impl-side painting only. |
473 NOTREACHED(); | 471 NOTREACHED(); |
474 return skia::RefPtr<SkPicture>(); | 472 return skia::RefPtr<SkPicture>(); |
475 } | 473 } |
476 | 474 |
477 } // namespace cc | 475 } // namespace cc |
OLD | NEW |