mirror of
https://github.com/PredatH0r/ChanSort.git
synced 2026-02-27 16:50:44 +01:00
- fix: Application failed to save config and didn't exit when the folder %LOCALAPPDATA%\ChanSort doesn't exist
This commit is contained in:
@@ -2516,10 +2516,17 @@ namespace ChanSort.Ui
|
||||
|
||||
private void MainForm_FormClosing(object sender, FormClosingEventArgs e)
|
||||
{
|
||||
if (this.PromptSaveAndContinue())
|
||||
this.SaveSettings();
|
||||
else
|
||||
e.Cancel = true;
|
||||
try
|
||||
{
|
||||
if (this.PromptSaveAndContinue())
|
||||
this.SaveSettings();
|
||||
else
|
||||
e.Cancel = true;
|
||||
}
|
||||
catch
|
||||
{
|
||||
// ignore - always allow to exit
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
@@ -57,6 +57,9 @@ namespace ChanSort.Ui.Properties
|
||||
|
||||
public void Save()
|
||||
{
|
||||
var folder = Path.GetDirectoryName(ConfigFilePath);
|
||||
Directory.CreateDirectory(folder);
|
||||
|
||||
using (var stream = new FileStream(ConfigFilePath, FileMode.Create))
|
||||
using (var writer = new StreamWriter(stream, System.Text.Encoding.UTF8))
|
||||
{
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
ChanSort Change Log
|
||||
===================
|
||||
|
||||
2019-07-25
|
||||
- fix: Application failed to save config and didn't exit when the folder %LOCALAPPDATA%\ChanSort doesn't exist
|
||||
|
||||
2019-07-20
|
||||
- user settings are now persisted across releases in %LOCALAPPDATA%\ChanSort\config.xml
|
||||
- fixed Sony sdb.xml DVB-T channel lists
|
||||
|
||||
Reference in New Issue
Block a user