| 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/layer_tree_host_impl.h" | 5 #include "cc/trees/layer_tree_host_impl.h" |
| 6 | 6 |
| 7 #include <cmath> | 7 #include <cmath> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 122 void SetMaxSwapsPendingOnImplThread(int max) override {} | 122 void SetMaxSwapsPendingOnImplThread(int max) override {} |
| 123 void DidSwapBuffersOnImplThread() override {} | 123 void DidSwapBuffersOnImplThread() override {} |
| 124 void DidSwapBuffersCompleteOnImplThread() override {} | 124 void DidSwapBuffersCompleteOnImplThread() override {} |
| 125 void OnCanDrawStateChanged(bool can_draw) override { | 125 void OnCanDrawStateChanged(bool can_draw) override { |
| 126 on_can_draw_state_changed_called_ = true; | 126 on_can_draw_state_changed_called_ = true; |
| 127 } | 127 } |
| 128 void NotifyReadyToActivate() override { | 128 void NotifyReadyToActivate() override { |
| 129 did_notify_ready_to_activate_ = true; | 129 did_notify_ready_to_activate_ = true; |
| 130 host_impl_->ActivateSyncTree(); | 130 host_impl_->ActivateSyncTree(); |
| 131 } | 131 } |
| 132 void NotifyReadyToDraw() override {} |
| 132 void SetNeedsRedrawOnImplThread() override { did_request_redraw_ = true; } | 133 void SetNeedsRedrawOnImplThread() override { did_request_redraw_ = true; } |
| 133 void SetNeedsRedrawRectOnImplThread(const gfx::Rect& damage_rect) override { | 134 void SetNeedsRedrawRectOnImplThread(const gfx::Rect& damage_rect) override { |
| 134 did_request_redraw_ = true; | 135 did_request_redraw_ = true; |
| 135 } | 136 } |
| 136 void SetNeedsAnimateOnImplThread() override { did_request_animate_ = true; } | 137 void SetNeedsAnimateOnImplThread() override { did_request_animate_ = true; } |
| 137 void SetNeedsManageTilesOnImplThread() override { | 138 void SetNeedsManageTilesOnImplThread() override { |
| 138 did_request_manage_tiles_ = true; | 139 did_request_manage_tiles_ = true; |
| 139 } | 140 } |
| 140 void DidInitializeVisibleTileOnImplThread() override { | 141 void DidInitializeVisibleTileOnImplThread() override { |
| 141 did_upload_visible_tile_ = true; | 142 did_upload_visible_tile_ = true; |
| (...skipping 7396 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7538 // surface. | 7539 // surface. |
| 7539 EXPECT_EQ(0, num_lost_surfaces_); | 7540 EXPECT_EQ(0, num_lost_surfaces_); |
| 7540 host_impl_->DidLoseOutputSurface(); | 7541 host_impl_->DidLoseOutputSurface(); |
| 7541 EXPECT_EQ(1, num_lost_surfaces_); | 7542 EXPECT_EQ(1, num_lost_surfaces_); |
| 7542 host_impl_->DidLoseOutputSurface(); | 7543 host_impl_->DidLoseOutputSurface(); |
| 7543 EXPECT_LE(1, num_lost_surfaces_); | 7544 EXPECT_LE(1, num_lost_surfaces_); |
| 7544 } | 7545 } |
| 7545 | 7546 |
| 7546 } // namespace | 7547 } // namespace |
| 7547 } // namespace cc | 7548 } // namespace cc |
| OLD | NEW |