Skip to content

Commit

Permalink
Reset storage state when resetting init patch
Browse files Browse the repository at this point in the history
The init patch updated prefs but not the in memory image.
Oops! Closes surge-synthesizer#5637
  • Loading branch information
baconpaul committed Dec 16, 2021
1 parent bfd8736 commit 038b6c9
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/surge-xt/gui/widgets/PatchSelector.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -544,6 +544,13 @@ void PatchSelector::showClassicMenu(bool single_category)
Surge::Storage::updateUserDefaultValue(
storage, Surge::Storage::InitialPatchCategoryType,
storage->patch_category[current_category].isFactory ? "Factory" : "User");

storage->initPatchName = Surge::Storage::getUserDefaultValue(
storage, Surge::Storage::InitialPatchName, "Init Saw");
storage->initPatchCategory = Surge::Storage::getUserDefaultValue(
storage, Surge::Storage::InitialPatchCategory, "Templates");
storage->initPatchCategoryType = Surge::Storage::getUserDefaultValue(
storage, Surge::Storage::InitialPatchCategoryType, "Factory");
});

contextMenu.addSeparator();
Expand Down

0 comments on commit 038b6c9

Please sign in to comment.