MCPcopy Create free account
hub / github.com/MrNeRF/LichtFeld-Studio / launchDevResourceScan

Method launchDevResourceScan

src/visualizer/gui/gui_manager.cpp:3595–3617  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3593 }
3594
3595 void GuiManager::launchDevResourceScan() {
3596 if (dev_resource_watch_.scan_future.valid())
3597 return;
3598
3599 auto rml_dir = dev_resource_watch_.rml_dir;
3600 auto locale_dir = dev_resource_watch_.locale_dir;
3601 auto previous_times = dev_resource_watch_.file_times;
3602 try {
3603 dev_resource_watch_.scan_future =
3604 std::async(std::launch::async,
3605 [rml_dir = std::move(rml_dir),
3606 locale_dir = std::move(locale_dir),
3607 previous_times = std::move(previous_times)]() mutable {
3608 return GuiManager::scanDevResourceFilesSnapshot(
3609 std::move(rml_dir),
3610 std::move(locale_dir),
3611 std::move(previous_times),
3612 true);
3613 });
3614 } catch (const std::exception& e) {
3615 LOG_WARN("Resource hot reload async scan could not start: {}", e.what());
3616 }
3617 }
3618
3619 bool GuiManager::consumeDevResourceScanResult() {
3620 if (!dev_resource_watch_.scan_future.valid())

Callers

nothing calls this directly

Calls 3

moveFunction · 0.85
validMethod · 0.45
whatMethod · 0.45

Tested by

no test coverage detected