public void ProductionAlterSaveDataOptions(ImageFile imageFile, Bitmap newBMP) { string newFileName; string newPath; int op = IOUser.ConsoleReadInput(ProductionSaveDataList); switch (op) { case 0: IOUser.ClearConsole(); Console.WriteLine("\nEnter a name for the new image (don't add .jpg):\n"); newFileName = IOUser.ConsoleSaveAs(imageFile.Origin, saveDirectory); newPath = Path.Combine(saveDirectory, newFileName); File.Copy(imageFile.Origin, newPath); IOUser.ConsoleOutput("Changes Saved! Going back to editing options"); imageFile.Bpm = newBMP; imageFile.Bpm.Save(newPath); Thread.Sleep(2000); break; case 1: IOUser.ClearConsole(); IOUser.ConsoleOutput("Changes Discarded! Going back to editing options"); Thread.Sleep(2000); break; } }
public void ProductionSaveDataOptions(string originBMPpath, Bitmap newBMP) { string newFileName; string newPath; string importFolderPath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "..\\..\\..\\PM-Images\\Imports"); int op = IOUser.ConsoleReadInput(ProductionSaveDataList); switch (op) { case 0: IOUser.ClearConsole(); Console.WriteLine("\nEnter a name for the new image (don't add .jpg):\n"); newFileName = IOUser.ConsoleSaveAs(originBMPpath, saveDirectory); newPath = Path.Combine(saveDirectory, newFileName); importFolderPath = Path.Combine(importFolderPath, newFileName); File.Copy(originBMPpath, newPath); IOUser.ConsoleOutput("Changes Saved and Copy created! Going back to editing options"); newBMP.Save(newPath); newBMP.Save(importFolderPath); Thread.Sleep(2000); break; case 1: IOUser.ClearConsole(); Console.WriteLine("\nEnter a name for the new image (don't add .jpg):\n"); newFileName = IOUser.ConsoleSaveAs(originBMPpath, saveDirectory); newPath = Path.Combine(saveDirectory, newFileName); File.Copy(originBMPpath, newPath); IOUser.ConsoleOutput("Changes Saved! Going back to editing options"); newBMP.Save(newPath); Thread.Sleep(2000); break; case 2: IOUser.ClearConsole(); IOUser.ConsoleOutput("Changes Discarded! Going back to editing options"); Thread.Sleep(2000); break; } }