private void btnSolveProblem_Click(object sender, RoutedEventArgs e)
        {
            ProblemManager.PreConfiguration preConfiguration = new ProblemManager.PreConfiguration();
            int problemSize = 0;
            if (ShowDialogWindow(preConfiguration) == true)
            {
                problemSize = preConfiguration.VM.NumPlaces;
            }
            else
            {
                return;
            }

            ProblemManager.ProblemManager problemManager = new ProblemManager.ProblemManager(problemSize);
            InputData input = null;

            if (ShowDialogWindow(problemManager) == true)
            {
                // bleble
                input = problemManager.ToInputData();
            }
            else
            {
                // Handle errors
                return;
            }

            SolutionWindow solutionWindow = new SolutionWindow(input);

            ShowDialogWindow(solutionWindow);
        }
        private void OpenSolutionCommandExecuted(object sender, ExecutedRoutedEventArgs e)
        {
            OpenFileDialog dialog = new OpenFileDialog();
            dialog.DefaultExt = "tssf";
            dialog.Filter = "Plik z rozwiązaniem problemu komiwojażera (*.tssf)|*.tssf";

            if (dialog.ShowDialog() == true)
            {
                SolutionData solution = null;
                try
                {
                    solution = parser.ReadSolutionFile(dialog.FileName);
                    SolutionWindow solutionWindow = new SolutionWindow(solution);
                    ShowDialogWindow(solutionWindow);
                }
                catch
                {
                    MessageBox.Show("Błąd podczas odczytywania pliku z rozwiązaniem", "Uwaga");
                }
            }
        }