| 639 | continue; |
| 640 | } |
| 641 | |
| 642 | (*onLayoutCallback)(); |
| 643 | } |
| 644 | } |
| 645 | |
| 646 | void ViewNodeTree::flushOnDrawCallbacks() { |
| 647 | if (_onDrawCallbacks.empty()) { |
| 648 | return; |
| 649 | } |
| 650 | |
| 651 | auto rootView = getRootView(); |
| 652 | if (rootView == nullptr) { |
| 653 | return; |
| 654 | } |
| 655 | |
| 656 | auto onDrawCallbacks = std::move(_onDrawCallbacks); |
| 657 | auto& transaction = getCurrentViewTransactionScope().transaction(); |
| 658 | for (const auto& onDrawCallback : onDrawCallbacks) { |
| 659 | if (onDrawCallback == nullptr) { |
| 660 | continue; |
| 661 | } |
| 662 | |
| 663 | transaction.scheduleOnNextDraw( |
| 664 | rootView, [onDrawCallback]() { (*onDrawCallback)({Value(TimePoint::now().getTime() * 1000.0)}); }); |
nothing calls this directly
no test coverage detected