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 <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <algorithm> | 10 #include <algorithm> |
(...skipping 2489 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2500 DCHECK_GT(status.main_thread_scrolling_reasons, | 2500 DCHECK_GT(status.main_thread_scrolling_reasons, |
2501 MainThreadScrollingReason::kMaxNonTransientScrollingReasons); | 2501 MainThreadScrollingReason::kMaxNonTransientScrollingReasons); |
2502 } | 2502 } |
2503 | 2503 |
2504 *scroll_on_main_thread = true; | 2504 *scroll_on_main_thread = true; |
2505 *main_thread_scrolling_reasons = status.main_thread_scrolling_reasons; | 2505 *main_thread_scrolling_reasons = status.main_thread_scrolling_reasons; |
2506 return NULL; | 2506 return NULL; |
2507 } | 2507 } |
2508 | 2508 |
2509 if (optional_has_ancestor_scroll_handler && | 2509 if (optional_has_ancestor_scroll_handler && |
2510 scroll_layer_impl->have_scroll_event_handlers()) | 2510 scroll_layer_impl->layer_tree_impl()->have_scroll_event_handlers()) |
2511 *optional_has_ancestor_scroll_handler = true; | 2511 *optional_has_ancestor_scroll_handler = true; |
aelias_OOO_until_Jul13
2016/01/28 22:25:07
Please delete this parameter, and instead in Layer
dtapuska
2016/01/29 21:23:34
Done.
| |
2512 | 2512 |
2513 if (status.thread == InputHandler::SCROLL_ON_IMPL_THREAD && | 2513 if (status.thread == InputHandler::SCROLL_ON_IMPL_THREAD && |
2514 !potentially_scrolling_layer_impl) { | 2514 !potentially_scrolling_layer_impl) { |
2515 potentially_scrolling_layer_impl = scroll_layer_impl; | 2515 potentially_scrolling_layer_impl = scroll_layer_impl; |
2516 } | 2516 } |
2517 } | 2517 } |
2518 | 2518 |
2519 // Falling back to the root scroll layer ensures generation of root overscroll | 2519 // Falling back to the root scroll layer ensures generation of root overscroll |
2520 // notifications while preventing scroll updates from being unintentionally | 2520 // notifications while preventing scroll updates from being unintentionally |
2521 // forwarded to the main thread. The inner viewport layer represents the | 2521 // forwarded to the main thread. The inner viewport layer represents the |
(...skipping 1369 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
3891 return task_runner_provider_->HasImplThread(); | 3891 return task_runner_provider_->HasImplThread(); |
3892 } | 3892 } |
3893 | 3893 |
3894 bool LayerTreeHostImpl::CommitToActiveTree() const { | 3894 bool LayerTreeHostImpl::CommitToActiveTree() const { |
3895 // In single threaded mode we skip the pending tree and commit directly to the | 3895 // In single threaded mode we skip the pending tree and commit directly to the |
3896 // active tree. | 3896 // active tree. |
3897 return !task_runner_provider_->HasImplThread(); | 3897 return !task_runner_provider_->HasImplThread(); |
3898 } | 3898 } |
3899 | 3899 |
3900 } // namespace cc | 3900 } // namespace cc |
OLD | NEW |