Use SohImGui::RequestCvarSaveOnNextTick

This commit is contained in:
Garrett Cox
2022-09-03 09:33:54 -05:00
parent 90bf5988ee
commit b92b1eaee6
@@ -518,7 +518,7 @@ void DrawNotes(bool resizeable = false) {
ItemTrackerNotes::TrackerNotesInputTextMultiline("##ItemTrackerNotes", &itemTrackerNotes, size, ImGuiInputTextFlags_AllowTabInput);
if (ImGui::IsItemDeactivatedAfterEdit() && IsValidSaveFile()) {
CVar_SetString(("gItemTrackerNotes" + std::to_string(gSaveContext.fileNum)).c_str(), std::string(std::begin(itemTrackerNotes), std::end(itemTrackerNotes)).c_str());
SohImGui::needs_save = true;
SohImGui::RequestCvarSaveOnNextTick();
}
ImGui::EndGroup();
}