Skip to content

Commit

Permalink
Fixed issue where the clear recording buttons got enabled when readin…
Browse files Browse the repository at this point in the history
…g combo recipes instead of dummy recordings

Corrected a typo when exporting dummy recordings
Import and export dialogs will only select the recordings/recipes folders by default once
  • Loading branch information
WesselKuipers committed Jul 30, 2017
1 parent 0aa50dc commit 63c75c5
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions GGRev2ComboRecipeManager.GUI/RecipeManagerForm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -189,10 +189,6 @@ private void btnReadRecipes_Click(object sender, EventArgs e)
btnImportRecipeSlot4.Enabled = true;
btnImportRecipeSlot5.Enabled = true;

btnClearDummySlot1.Enabled = true;
btnClearDummySlot2.Enabled = true;
btnClearDummySlot3.Enabled = true;

btnExportRecipeSlot1.Enabled = ComboRecipes[0].CharacterCode != CharacterCode.Unknown;
btnExportRecipeSlot2.Enabled = ComboRecipes[1].CharacterCode != CharacterCode.Unknown;
btnExportRecipeSlot3.Enabled = ComboRecipes[2].CharacterCode != CharacterCode.Unknown;
Expand Down Expand Up @@ -230,8 +226,7 @@ private ComboRecipe ImportComboRecipe(int slotNr)
var ofd = new OpenFileDialog
{
Filter = "Guilty Gear Combo Recipe|*.ggcr",
InitialDirectory = Path.GetFullPath(AppDomain.CurrentDomain.BaseDirectory + "\\Recipes"),
RestoreDirectory = true
InitialDirectory = Path.GetFullPath(AppDomain.CurrentDomain.BaseDirectory + "\\Recipes")
};

if (ofd.ShowDialog() == DialogResult.OK)
Expand Down Expand Up @@ -268,8 +263,7 @@ private DummyRecording ImportDummyRecording(int slotNr)
var ofd = new OpenFileDialog
{
Filter = "Guilty Gear Dummy Recording|*.ggdr",
InitialDirectory = Path.GetFullPath(AppDomain.CurrentDomain.BaseDirectory + "\\Recordings"),
RestoreDirectory = true
InitialDirectory = Path.GetFullPath(AppDomain.CurrentDomain.BaseDirectory + "\\Recordings")
};

if (ofd.ShowDialog() == DialogResult.OK)
Expand Down Expand Up @@ -299,7 +293,7 @@ private void ExportDummyRecording(int slotNr)

var sfd = new SaveFileDialog
{
Filter = "Guilty Gear Combo Recipe|*.ggdr",
Filter = "Guilty Gear Dummy Recording|*.ggdr",
FileName = $"Combo{slotNr + 1}.ggdr",
InitialDirectory = Path.GetFullPath(AppDomain.CurrentDomain.BaseDirectory + "\\Recordings")
};
Expand Down Expand Up @@ -329,6 +323,10 @@ private void btnReadDummyRecordings_Click(object sender, EventArgs e)
btnExportDummySlot1.Enabled = DummyRecordings[0].RecordingData[4] > 0;
btnExportDummySlot2.Enabled = DummyRecordings[1].RecordingData[4] > 0;
btnExportDummySlot3.Enabled = DummyRecordings[2].RecordingData[4] > 0;

btnClearDummySlot1.Enabled = true;
btnClearDummySlot2.Enabled = true;
btnClearDummySlot3.Enabled = true;
}
}
}

0 comments on commit 63c75c5

Please sign in to comment.