| 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 #include "ui/compositor/compositor.h" | 5 #include "ui/compositor/compositor.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <deque> | 8 #include <deque> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 718 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 729 | 729 |
| 730 void Compositor::Layout() { | 730 void Compositor::Layout() { |
| 731 // We're sending damage that will be addressed during this composite | 731 // We're sending damage that will be addressed during this composite |
| 732 // cycle, so we don't need to schedule another composite to address it. | 732 // cycle, so we don't need to schedule another composite to address it. |
| 733 disable_schedule_composite_ = true; | 733 disable_schedule_composite_ = true; |
| 734 if (root_layer_) | 734 if (root_layer_) |
| 735 root_layer_->SendDamagedRects(); | 735 root_layer_->SendDamagedRects(); |
| 736 disable_schedule_composite_ = false; | 736 disable_schedule_composite_ = false; |
| 737 } | 737 } |
| 738 | 738 |
| 739 scoped_ptr<cc::OutputSurface> Compositor::CreateOutputSurface() { | 739 scoped_ptr<cc::OutputSurface> Compositor::CreateOutputSurface(bool fallback) { |
| 740 return make_scoped_ptr( | 740 return make_scoped_ptr( |
| 741 ContextFactory::GetInstance()->CreateOutputSurface(this)); | 741 ContextFactory::GetInstance()->CreateOutputSurface(this)); |
| 742 } | 742 } |
| 743 | 743 |
| 744 void Compositor::DidCommit() { | 744 void Compositor::DidCommit() { |
| 745 DCHECK(!IsLocked()); | 745 DCHECK(!IsLocked()); |
| 746 FOR_EACH_OBSERVER(CompositorObserver, | 746 FOR_EACH_OBSERVER(CompositorObserver, |
| 747 observer_list_, | 747 observer_list_, |
| 748 OnCompositingDidCommit(this)); | 748 OnCompositingDidCommit(this)); |
| 749 } | 749 } |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 836 COMPOSITOR_EXPORT void DisableTestCompositor() { | 836 COMPOSITOR_EXPORT void DisableTestCompositor() { |
| 837 ResetImplicitFactory(); | 837 ResetImplicitFactory(); |
| 838 g_test_compositor_enabled = false; | 838 g_test_compositor_enabled = false; |
| 839 } | 839 } |
| 840 | 840 |
| 841 COMPOSITOR_EXPORT bool IsTestCompositorEnabled() { | 841 COMPOSITOR_EXPORT bool IsTestCompositorEnabled() { |
| 842 return g_test_compositor_enabled; | 842 return g_test_compositor_enabled; |
| 843 } | 843 } |
| 844 | 844 |
| 845 } // namespace ui | 845 } // namespace ui |
| OLD | NEW |