| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 "cc/trees/layer_tree_host.h" | 5 #include "cc/trees/layer_tree_host.h" |
| 6 | 6 |
| 7 #include "base/memory/weak_ptr.h" | 7 #include "base/memory/weak_ptr.h" |
| 8 #include "cc/layers/layer.h" | 8 #include "cc/layers/layer.h" |
| 9 #include "cc/layers/layer_impl.h" | 9 #include "cc/layers/layer_impl.h" |
| 10 #include "cc/layers/picture_layer.h" | 10 #include "cc/layers/picture_layer.h" |
| (...skipping 1055 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1066 if (!task_runner_->BelongsToCurrentThread()) | 1066 if (!task_runner_->BelongsToCurrentThread()) |
| 1067 ADD_FAILURE() << "Animate called on wrong thread"; | 1067 ADD_FAILURE() << "Animate called on wrong thread"; |
| 1068 } | 1068 } |
| 1069 | 1069 |
| 1070 virtual void MainThreadHasStoppedFlinging() OVERRIDE { | 1070 virtual void MainThreadHasStoppedFlinging() OVERRIDE { |
| 1071 if (!task_runner_->BelongsToCurrentThread()) | 1071 if (!task_runner_->BelongsToCurrentThread()) |
| 1072 ADD_FAILURE() << "MainThreadHasStoppedFlinging called on wrong thread"; | 1072 ADD_FAILURE() << "MainThreadHasStoppedFlinging called on wrong thread"; |
| 1073 *received_stop_flinging_ = true; | 1073 *received_stop_flinging_ = true; |
| 1074 } | 1074 } |
| 1075 | 1075 |
| 1076 virtual void DidOverscroll(const gfx::Vector2dF& accumulated_overscroll, | 1076 virtual void DidOverscroll( |
| 1077 const gfx::Vector2dF& latest_overscroll_delta) | 1077 const gfx::PointF& causal_event_viewport_point, |
| 1078 OVERRIDE { | 1078 const gfx::Vector2dF& accumulated_overscroll, |
| 1079 const gfx::Vector2dF& latest_overscroll_delta) OVERRIDE { |
| 1079 if (!task_runner_->BelongsToCurrentThread()) | 1080 if (!task_runner_->BelongsToCurrentThread()) |
| 1080 ADD_FAILURE() << "DidOverscroll called on wrong thread"; | 1081 ADD_FAILURE() << "DidOverscroll called on wrong thread"; |
| 1081 } | 1082 } |
| 1082 | 1083 |
| 1083 private: | 1084 private: |
| 1084 base::SingleThreadTaskRunner* task_runner_; | 1085 base::SingleThreadTaskRunner* task_runner_; |
| 1085 bool* received_stop_flinging_; | 1086 bool* received_stop_flinging_; |
| 1086 }; | 1087 }; |
| 1087 | 1088 |
| 1088 void BindInputHandlerOnCompositorThread( | 1089 void BindInputHandlerOnCompositorThread( |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1213 RunTest(true, false, true); | 1214 RunTest(true, false, true); |
| 1214 } | 1215 } |
| 1215 | 1216 |
| 1216 TEST_F(LayerTreeHostScrollTestLayerStructureChange, ScrollDestroyWholeTree) { | 1217 TEST_F(LayerTreeHostScrollTestLayerStructureChange, ScrollDestroyWholeTree) { |
| 1217 scroll_destroy_whole_tree_ = true; | 1218 scroll_destroy_whole_tree_ = true; |
| 1218 RunTest(true, false, true); | 1219 RunTest(true, false, true); |
| 1219 } | 1220 } |
| 1220 | 1221 |
| 1221 } // namespace | 1222 } // namespace |
| 1222 } // namespace cc | 1223 } // namespace cc |
| OLD | NEW |