/// <summary>
        /// Invokes if the 'Edit Feature'-option in the context menu strip was clicked.
        ///
        /// This will open a dialog to edit the feature at the position where the context
        /// menu strip was placed.
        /// </summary>
        /// <param name="sender">Sender</param>
        /// <param name="e">Event</param>
        private void editFeatureToolStripMenuItem_Click(object sender, EventArgs e)
        {
            ConfigurationOption selected;

            if (this.currentNode == null)
            {
                selected = null;
            }
            else if (this.currentNode.Text == "root")
            {
                selected = GlobalState.varModel.Root;
            }
            else
            {
                selected = GlobalState.varModel.getOption(this.currentNode.Text);
            }

            EditOptionDialog dlg = new EditOptionDialog(this, selected);

            dlg.ShowDialog();

            dataSaved = false;

            InitTreeView();
        }
        /// <summary>
        /// Invokes if the 'Edit -> Edit Options'-option in the menu strip was clicked.
        ///
        /// This will open the corresponding dialog for editing options.
        /// </summary>
        /// <param name="sender">Sender</param>
        /// <param name="e">Event</param>
        private void editOptionsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            EditOptionDialog form = new EditOptionDialog(this, null);

            form.Show();

            dataSaved = false;
        }
Exemple #3
0
        private void buttonEditFeatures_Click(object sender, EventArgs e)
        {
            if (GlobalState.varModel == null)
            {
                return;
            }
            EditOptionDialog featureEditDlg = new EditOptionDialog();

            featureEditDlg.ShowDialog();
        }
 private void buttonEditFeatures_Click(object sender, EventArgs e)
 {
     if (GlobalState.varModel == null)
         return;
     EditOptionDialog featureEditDlg = new EditOptionDialog(this);
     featureEditDlg.ShowDialog();
 }
        /// <summary>
        /// Invokes if the 'Edit -> Edit Options'-option in the menu strip was clicked.
        /// 
        /// This will open the corresponding dialog for editing options.
        /// </summary>
        /// <param name="sender">Sender</param>
        /// <param name="e">Event</param>
        private void editOptionsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            EditOptionDialog form = new EditOptionDialog(this, null);
            form.Show();

            dataSaved = false;
        }
        /// <summary>
        /// Invokes if the 'Edit Feature'-option in the context menu strip was clicked.
        /// 
        /// This will open a dialog to edit the feature at the position where the context
        /// menu strip was placed.
        /// </summary>
        /// <param name="sender">Sender</param>
        /// <param name="e">Event</param>
        private void editFeatureToolStripMenuItem_Click(object sender, EventArgs e)
        {
            ConfigurationOption selected;

            if (this.currentNode == null)
                selected = null;
            else if (this.currentNode.Text == "root")
                selected = GlobalState.varModel.Root;
            else
                selected = GlobalState.varModel.getOption(this.currentNode.Text);

            EditOptionDialog dlg = new EditOptionDialog(this, selected);
            dlg.ShowDialog();

            dataSaved = false;

            InitTreeView();
        }