| 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 <algorithm> | 7 #include <algorithm> |
| 8 #include <cmath> | 8 #include <cmath> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.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 7492 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7634 // surface. | 7635 // surface. |
| 7635 EXPECT_EQ(0, num_lost_surfaces_); | 7636 EXPECT_EQ(0, num_lost_surfaces_); |
| 7636 host_impl_->DidLoseOutputSurface(); | 7637 host_impl_->DidLoseOutputSurface(); |
| 7637 EXPECT_EQ(1, num_lost_surfaces_); | 7638 EXPECT_EQ(1, num_lost_surfaces_); |
| 7638 host_impl_->DidLoseOutputSurface(); | 7639 host_impl_->DidLoseOutputSurface(); |
| 7639 EXPECT_LE(1, num_lost_surfaces_); | 7640 EXPECT_LE(1, num_lost_surfaces_); |
| 7640 } | 7641 } |
| 7641 | 7642 |
| 7642 } // namespace | 7643 } // namespace |
| 7643 } // namespace cc | 7644 } // namespace cc |
| OLD | NEW |