sys: Add functionality to clear recent files (#395)

* sys: Add functionality to clear recent files

* sys: Remove clear recent files from welcome window
This commit is contained in:
draftshade
2022-01-08 23:17:47 +01:00
committed by GitHub
parent f45cc3fc73
commit fe04d05c28
5 changed files with 13 additions and 0 deletions

View File

@@ -333,6 +333,15 @@ namespace hex::plugin::builtin {
}
}
ImGui::Separator();
if (ImGui::MenuItem("hex.builtin.view.hexeditor.menu.file.clear_recent"_lang)) {
SharedData::recentFilePaths.clear();
ContentRegistry::Settings::write(
"hex.builtin.setting.imhex",
"hex.builtin.setting.imhex.recent_files",
std::vector<std::string>{});
}
ImGui::EndMenu();
}