Esempio n. 1
0
        void itemAddFolder_Click(object sender, System.Windows.RoutedEventArgs e)
        {
            InputBox dialog = new InputBox();
            if ((bool)dialog.ShowDialog())
            {
                Folder folder = new Folder(this) { Name = dialog.Content, Path = "/" + dialog.Content };
                System.IO.Directory.CreateDirectory(Path + folder.Path);
                Items.Add(folder);

                Save();
                ProjectManager.GetManager().ProjectUpdated();
            }
        }
Esempio n. 2
0
        void itemAddFile_Click(object sender, System.Windows.RoutedEventArgs e)
        {
            InputBox dialog = new InputBox();
            if ((bool)dialog.ShowDialog())
            {
                Source file = new Source(this) { Name = dialog.Content, Path = "/" + dialog.Content + ".snl" };
                System.IO.File.Create(Path + file.Path).Close();
                Items.Add(file);

                Save();
                ProjectManager.GetManager().ProjectUpdated();
            }
        }