Ejemplo n.º 1
0
        private void add_property_button_Click(object sender, EventArgs e)
        {
            ExtraPropertiesEditor property_editor = new ExtraPropertiesEditor("", "", "", "");
            DialogResult          result          = property_editor.ShowDialog();

            if (result == DialogResult.OK)
            {
                //Add a new Row
                DOLConfigParser.addExtraOptionsRow(this.extraOptions, property_editor.propertyName, property_editor.propertyType, (object)property_editor.propertyValue, "");
            }
        }
Ejemplo n.º 2
0
        private void edit_property(int rowIndex)
        {
            string property_name        = Convert.ToString(extra_options_datagrid.Rows[rowIndex].Cells["property"].Value);
            string property_type        = Convert.ToString(extra_options_datagrid.Rows[rowIndex].Cells["type"].Value);
            object property_value       = extra_options_datagrid.Rows[rowIndex].Cells["value"].Value;
            string property_description = Convert.ToString(extra_options_datagrid.Rows[rowIndex].Cells["description"].Value);

            ExtraPropertiesEditor property_editor = new ExtraPropertiesEditor(property_name, property_type, property_value, property_description);
            DialogResult          result          = property_editor.ShowDialog();

            if (result == DialogResult.OK)
            {
                extra_options_datagrid.Rows[rowIndex].Cells["property"].Value = (object)property_editor.propertyName;
                extra_options_datagrid.Rows[rowIndex].Cells["type"].Value     = (object)property_editor.propertyType;
                extra_options_datagrid.Rows[rowIndex].Cells["value"].Value    = (object)property_editor.propertyValue;
            }
        }
Ejemplo n.º 3
0
		private void add_property_button_Click(object sender, EventArgs e)
		{
			ExtraPropertiesEditor property_editor = new ExtraPropertiesEditor("", "", "", "");
			DialogResult result = property_editor.ShowDialog();
			if (result == DialogResult.OK)
			{
				//Add a new Row
				DOLConfigParser.addExtraOptionsRow(this.extraOptions, property_editor.propertyName, property_editor.propertyType, (object)property_editor.propertyValue, "");
			}
		}
Ejemplo n.º 4
0
		private void edit_property(int rowIndex) {
			string property_name = Convert.ToString(extra_options_datagrid.Rows[rowIndex].Cells["property"].Value);
			string property_type = Convert.ToString(extra_options_datagrid.Rows[rowIndex].Cells["type"].Value);
			object property_value = extra_options_datagrid.Rows[rowIndex].Cells["value"].Value;
			string property_description = Convert.ToString(extra_options_datagrid.Rows[rowIndex].Cells["description"].Value);

			ExtraPropertiesEditor property_editor = new ExtraPropertiesEditor(property_name, property_type, property_value, property_description);
			DialogResult result = property_editor.ShowDialog();
			if (result == DialogResult.OK)
			{
				extra_options_datagrid.Rows[rowIndex].Cells["property"].Value = (object)property_editor.propertyName;
				extra_options_datagrid.Rows[rowIndex].Cells["type"].Value = (object)property_editor.propertyType;
				extra_options_datagrid.Rows[rowIndex].Cells["value"].Value = (object)property_editor.propertyValue;
			}
		}