mirror of https://github.com/WerWolv/ImHex.git
sys: Clear project after loading crash backup
This commit is contained in:
parent
dbcb13f473
commit
ef3627321c
|
@ -1 +1 @@
|
||||||
Subproject commit 58f1702be038aca08a01ddd61d41b1c724b43a31
|
Subproject commit f5ae1a5b85c6fd7ef07e133fae480a6cda08dd55
|
|
@ -174,6 +174,11 @@ namespace hex::plugin::builtin {
|
||||||
ImGui::SetCursorPosX(width / 9);
|
ImGui::SetCursorPosX(width / 9);
|
||||||
if (ImGui::Button("hex.builtin.welcome.safety_backup.restore"_lang, ImVec2(width / 3, 0))) {
|
if (ImGui::Button("hex.builtin.welcome.safety_backup.restore"_lang, ImVec2(width / 3, 0))) {
|
||||||
ProjectFile::load(s_safetyBackupPath);
|
ProjectFile::load(s_safetyBackupPath);
|
||||||
|
ProjectFile::clearPath();
|
||||||
|
|
||||||
|
for (const auto &provider : ImHexApi::Provider::getProviders())
|
||||||
|
provider->markDirty();
|
||||||
|
|
||||||
fs::remove(s_safetyBackupPath);
|
fs::remove(s_safetyBackupPath);
|
||||||
|
|
||||||
ImGui::CloseCurrentPopup();
|
ImGui::CloseCurrentPopup();
|
||||||
|
|
Loading…
Reference in New Issue