예제 #1
0
        void OnAddConfiguration(object sender, EventArgs e)
        {
            var okCommand = new Command(GettextCatalog.GetString("Create"));

            using (var dlg = new RunConfigurationNameDialog(ParentWindow, "", okCommand, panel.Configurations.Select(c => c.EditedConfig.Name))) {
                dlg.Title = GettextCatalog.GetString("New Configuration");
                if (dlg.Run() == okCommand)
                {
                    var config = panel.Project.CreateRunConfiguration(dlg.NewName);
                    panel.AddConfiguration(config);
                    Fill();
                }
            }
        }
예제 #2
0
        void OnRenameConfiguration(object sender, EventArgs e)
        {
            var config    = (ProjectRunConfiguration)list.SelectedConfiguration;
            var okCommand = new Command(GettextCatalog.GetString("Rename"));

            using (var dlg = new RunConfigurationNameDialog(ParentWindow, config.Name, okCommand, panel.Configurations.Select(c => c.EditedConfig.Name))) {
                dlg.Title = GettextCatalog.GetString("Rename Configuration");
                if (dlg.Run() != Command.Cancel)
                {
                    var copy = panel.Project.CloneRunConfiguration(config, dlg.NewName);
                    panel.ReplaceConfiguration(config, copy);
                    Fill();
                }
            }
        }
        void OnCopyConfiguration(object sender, EventArgs e)
        {
            var config    = (MultiItemSolutionRunConfiguration)list.SelectedConfiguration;
            var okCommand = new Command(GettextCatalog.GetString("Create"));

            using (var dlg = new RunConfigurationNameDialog(ParentWindow, config.Name, okCommand, panel.Configurations.Select(c => c.EditedConfig.Name))) {
                dlg.Title = GettextCatalog.GetString("Duplicate Configuration");
                if (dlg.Run() == okCommand)
                {
                    var copy = new MultiItemSolutionRunConfiguration(config, dlg.NewName);
                    panel.AddConfiguration(copy);
                    Fill();
                }
            }
        }
		void OnRenameConfiguration (object sender, EventArgs e)
		{
			var config = (MultiItemSolutionRunConfiguration)list.SelectedConfiguration;
			var okCommand = new Command (GettextCatalog.GetString ("Rename"));
			using (var dlg = new RunConfigurationNameDialog (ParentWindow, config.Name, okCommand, panel.Configurations.Select (c => c.EditedConfig.Name))) {
				dlg.Title = GettextCatalog.GetString ("Rename Configuration");
				if (dlg.Run () != Command.Cancel) {
					var copy = new MultiItemSolutionRunConfiguration (config, dlg.NewName);
					panel.ReplaceConfiguration (config, copy);
					Fill ();
				}
			}
		}
		void OnAddConfiguration (object sender, EventArgs e)
		{
			var okCommand = new Command (GettextCatalog.GetString ("Create"));
			using (var dlg = new RunConfigurationNameDialog (ParentWindow, "", okCommand, panel.Configurations.Select (c => c.EditedConfig.Name))) {
				dlg.Title = GettextCatalog.GetString ("New Configuration");
				if (dlg.Run () == okCommand) {
					var config = new MultiItemSolutionRunConfiguration (dlg.NewName, dlg.NewName);
					panel.AddConfiguration (config);
					Fill ();
				}
			}
		}
예제 #6
0
		void OnCopyConfiguration (object sender, EventArgs e)
		{
			var config = (ProjectRunConfiguration)list.SelectedConfiguration;
			var okCommand = new Command (GettextCatalog.GetString ("Create"));
			using (var dlg = new RunConfigurationNameDialog (ParentWindow, config.Name, okCommand, panel.Configurations.Select (c => c.EditedConfig.Name))) {
				dlg.Title = GettextCatalog.GetString ("Duplicate Configuration");
				if (dlg.Run () == okCommand) {
					var copy = panel.Project.CloneRunConfiguration (config, dlg.NewName);
					panel.AddConfiguration (copy);
					Fill ();
				}
			}
		}