| 4903 | } |
| 4904 | |
| 4905 | static Result<Ref<Valdi::LoadedAsset>> loadSync(RuntimeWrapper& runtimeWrapper, const Ref<Asset>& asset) { |
| 4906 | auto observer = makeShared<AssetLoadObserverImpl>(); |
| 4907 | asset->addLoadObserver(observer, snap::valdi_core::AssetOutputType::Dummy, 0, 0, Value()); |
| 4908 | |
| 4909 | runtimeWrapper.mainQueue->runUntilTrue([&]() { return !observer->_result.empty(); }); |
| 4910 | |
| 4911 | return observer->_result; |
| 4912 | } |
| 4913 | |
| 4914 | private: |
| 4915 | Result<Ref<Valdi::LoadedAsset>> _result; |
nothing calls this directly
no test coverage detected