1 #ifdef RCT_NEW_ARCH_ENABLED 2 3 #include "FabricUtils.h" 4 5 #include <react/renderer/debug/SystraceSection.h> 6 #include <react/renderer/uimanager/UIManagerBinding.h> 7 8 using namespace facebook::react; 9 10 namespace reanimated { 11 12 #ifdef ANDROID getRuntimeExecutorFromBinding(Binding * binding)13RuntimeExecutor getRuntimeExecutorFromBinding(Binding *binding) { 14 BindingPublic *bindingPublic = reinterpret_cast<BindingPublic *>(binding); 15 SchedulerPublic *schedulerPublic = 16 reinterpret_cast<SchedulerPublic *>((bindingPublic->scheduler_).get()); 17 return schedulerPublic->runtimeExecutor_; 18 } 19 #endif 20 getContextContainerFromUIManager(const UIManager * uiManager)21std::shared_ptr<const ContextContainer> getContextContainerFromUIManager( 22 const UIManager *uiManager) { 23 return reinterpret_cast<const UIManagerPublic *>(uiManager) 24 ->contextContainer_; 25 } 26 27 } // namespace reanimated 28 29 #endif // RCT_NEW_ARCH_ENABLED 30