private void EditExpression(FunctionParameters expression)
        {
            if (expression != null)
            {
                FunctionParameters newExpression = (FunctionParameters)expression.Clone();

                NugenCCalcBase component = null;
                if (_is3DDesigner)
                {
                    component = new NugenCCalc3D();
                    component.FunctionParameters = (Function3DParameters)newExpression;
                }
                else
                {
                    component = new NugenCCalc2D();
                    component.FunctionParameters = (Function2DParameters)newExpression;
                }
                ExpressionForm frmExpression = new ExpressionForm(component);

                if (frmExpression.ShowDialog() == DialogResult.OK)
                {
                    expression.Name         = frmExpression.Component.FunctionParameters.Name;
                    expression.CodeLanguage = frmExpression.Component.FunctionParameters.CodeLanguage;
                    expression.Code         = frmExpression.Component.FunctionParameters.Code;
                }
            }
            this.expressionExplorer.Init();
        }
예제 #2
0
		public DestinationView3D(NugenCCalc3D component)
		{
			_component = component;

			// This call is required by the Windows Form Designer.
			InitializeComponent();
		}
예제 #3
0
        private void EditEquation(FunctionParameters equation)
        {
            if (equation != null)
            {
                FunctionParameters newEquation = (FunctionParameters)equation.Clone();

                NugenCCalcBase component = null;
                if (_is3DDesigner)
                {
                    component = new NugenCCalc3D();
                    component.FunctionParameters = (Function3DParameters)newEquation;
                }
                else
                {
                    component = new NugenCCalc2D();
                    component.FunctionParameters = (Function2DParameters)newEquation;
                }


                EquationForm frmEquation = new EquationForm(component);

                if (frmEquation.ShowDialog() == DialogResult.OK)
                {
                    equation.Name    = component.FunctionParameters.Name;
                    equation.Formula = component.FunctionParameters.Formula;
                    //equation.FunctionType = frmEquation.Equation.FunctionType;
                }
            }
            this.equationExplorer.Init();
        }
예제 #4
0
        public DestinationView3D(NugenCCalc3D component)
        {
            _component = component;

            // This call is required by the Windows Form Designer.
            InitializeComponent();
        }
 public NugenCCalc3DDesignerForm(NugenCCalc3D component) : this()
 {
     _component = component;
 }
		public NugenCCalc3DDesignerForm(NugenCCalc3D component) : this()
		{
			_component = component;
		}
		private void EditExpression(FunctionParameters expression)
		{
			if (expression != null)
			{
				FunctionParameters newExpression = (FunctionParameters)expression.Clone();

				NugenCCalcBase component = null;
				if (_is3DDesigner)
				{
					component = new NugenCCalc3D();
					component.FunctionParameters = (Function3DParameters)newExpression;
				}
				else
				{
					component = new NugenCCalc2D();
					component.FunctionParameters = (Function2DParameters)newExpression;
				}
				ExpressionForm frmExpression = new ExpressionForm(component);

				if (frmExpression.ShowDialog() == DialogResult.OK)
				{
					expression.Name = frmExpression.Component.FunctionParameters.Name;
					expression.CodeLanguage = frmExpression.Component.FunctionParameters.CodeLanguage;
					expression.Code = frmExpression.Component.FunctionParameters.Code;
				}
			}
			this.expressionExplorer.Init();

		}
		private void EditEquation(FunctionParameters equation)
		{
			if (equation != null)
			{
				FunctionParameters newEquation = (FunctionParameters)equation.Clone();

				NugenCCalcBase component = null;
				if (_is3DDesigner)
				{
					component = new NugenCCalc3D();
					component.FunctionParameters = (Function3DParameters)newEquation;
				}
				else
				{
					component = new NugenCCalc2D();
					component.FunctionParameters = (Function2DParameters)newEquation;
				}


				EquationForm frmEquation = new EquationForm(component);

				if (frmEquation.ShowDialog() == DialogResult.OK)
				{
					equation.Name = component.FunctionParameters.Name;
					equation.Formula = component.FunctionParameters.Formula;
					//equation.FunctionType = frmEquation.Equation.FunctionType;
				}
			}
			this.equationExplorer.Init();
		}