MCPcopy Create free account
hub / github.com/OpenLoco/OpenLoco / resetShortcuts

Function resetShortcuts

src/OpenLoco/src/Config.cpp:366–379  ·  view source on GitHub ↗

0x004BE3F3

Source from the content-addressed store, hash-verified

364
365 // 0x004BE3F3
366 void resetShortcuts()
367 {
368 const auto& shortcutDefs = Input::ShortcutManager::getList();
369
370 auto& shortcuts = _config.shortcuts;
371 shortcuts.clear();
372
373 for (const auto& def : shortcutDefs)
374 {
375 shortcuts[def.id] = YAML::Node(def.defaultBinding).as<KeyboardShortcut>();
376 }
377
378 write();
379 }
380}

Callers

nothing calls this directly

Calls 2

writeFunction · 0.85
clearMethod · 0.45

Tested by

no test coverage detected