public bool Execute(ProjectFolder folder) { var model = new ViewMobilizerModel(folder); var form = new ViewMobilizerForm(model); var result = form.ShowDialog(); if (result == DialogResult.OK) { foreach (var view in model.SelectedViews) { var file = view.Item1; string mobileFileName = view.Item2; File.Copy(file.FullName, mobileFileName); folder.DteProjectItems.AddFromFile(mobileFileName); } } return true; }
public bool Execute(ProjectFolder folder) { var model = new ViewMobilizerModel(folder); var form = new ViewMobilizerForm(model); var result = form.ShowDialog(); if (result == DialogResult.OK) { foreach (var view in model.SelectedViews) { var file = view.Item1; string mobileFileName = view.Item2; File.Copy(file.FullName, mobileFileName); folder.DteProjectItems.AddFromFile(mobileFileName); } } return(true); }