Fixed threads and chunk loading error
This commit is contained in:
parent
764a439645
commit
2b195946e3
1 changed files with 14 additions and 4 deletions
|
|
@ -386,9 +386,9 @@ public partial class MainForm
|
||||||
openFileDialog.Filter = "Setup (*.xml)|*.xml|All valid files (*.*)|*.*";
|
openFileDialog.Filter = "Setup (*.xml)|*.xml|All valid files (*.*)|*.*";
|
||||||
openFileDialog.FilterIndex = 0;
|
openFileDialog.FilterIndex = 0;
|
||||||
openFileDialog.RestoreDirectory = true;
|
openFileDialog.RestoreDirectory = true;
|
||||||
|
|
||||||
if (DialogResult.OK != openFileDialog.ShowDialog()) return;
|
if (DialogResult.OK != openFileDialog.ShowDialog()) return;
|
||||||
|
|
||||||
var ilNome = openFileDialog.FileName;
|
var ilNome = openFileDialog.FileName;
|
||||||
_parametriSetup.NomeFileSetup = ilNome;
|
_parametriSetup.NomeFileSetup = ilNome;
|
||||||
_parametriSetup.CaricaParametriSetup();
|
_parametriSetup.CaricaParametriSetup();
|
||||||
|
|
@ -480,8 +480,18 @@ public partial class MainForm
|
||||||
Text = "Image Catalog - " + LeggiSoloNomeFile(ilNome);
|
Text = "Image Catalog - " + LeggiSoloNomeFile(ilNome);
|
||||||
|
|
||||||
// 2021
|
// 2021
|
||||||
Model.ChunkSize = int.Parse(_parametriSetup.LeggiParametroString("ChunkSize"));
|
if (int.TryParse(_parametriSetup.LeggiParametroString("ChunkSize"), out var chunkSize))
|
||||||
Model.ThreadsCount = int.Parse(_parametriSetup.LeggiParametroString("ThreadsCount"));
|
{
|
||||||
|
Model.ChunkSize = chunkSize;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (int.TryParse(_parametriSetup.LeggiParametroString("ThreadsCount"), out var threadsCount))
|
||||||
|
{
|
||||||
|
Model.ThreadsCount = threadsCount;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Model.ChunkSize = int.Parse(_parametriSetup.LeggiParametroString("ChunkSize"));
|
||||||
|
// Model.ThreadsCount = int.Parse(_parametriSetup.LeggiParametroString("ThreadsCount"));
|
||||||
}
|
}
|
||||||
|
|
||||||
private void SetPicSettings(string SourcePath, string DestPath)
|
private void SetPicSettings(string SourcePath, string DestPath)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue