| 312 | |
| 313 | |
| 314 | static void SaveLoadHotkeys(bool save) |
| 315 | { |
| 316 | IniFile ini{}; |
| 317 | ini.LoadFromDisk(_hotkeys_file, NO_DIRECTORY); |
| 318 | |
| 319 | for (HotkeyList *list : *_hotkey_lists) { |
| 320 | if (save) { |
| 321 | list->Save(ini); |
| 322 | } else { |
| 323 | list->Load(ini); |
| 324 | } |
| 325 | } |
| 326 | |
| 327 | if (save) ini.SaveToDisk(_hotkeys_file); |
| 328 | } |
| 329 | |
| 330 | |
| 331 | /** Load the hotkeys from the config file */ |
no test coverage detected