Esempio n. 1
0
        private void Import_Click(object sender, RoutedEventArgs e)
        {
            TileManagerViewModel vm     = DataContext as TileManagerViewModel;
            OpenFileDialog       dialog = new OpenFileDialog()
            {
                Filter       = "Collection package|*.col",
                AddExtension = true
            };


            if (dialog.ShowDialog() == true)
            {
                CollectionSet imported = CollectionSet.ImportFromFile(dialog.FileName);
                vm.LoadedCollections.Add(imported);
                vm.SelectedCollection = imported;
            }
        }