Esempio n. 1
0
        private void AddFile(bool isAddition)
        {
            var dialog = new OpenFileDialog {
                Multiselect = true
            };

            if (dialog.ShowDialog() ?? false)
            {
                foreach (var filePath in dialog.FileNames)
                {
                    var file = new FileViewModel {
                        IsAddition = isAddition, Path = filePath
                    };
                    files.Add(file);
                    model.AddFile(filePath, isAddition);
                }
            }
        }