Esempio n. 1
0
        public ObjectNet(string name, ObjectSequence inObj, ObjectSequence outObj, Control _ControlHandle)
        {
            netName = name;
            inputObject = inObj;
            inputObject.UpdatePosition += new ObjectSequence.ObjectPosistionMove(inputObject_UpdatePosition);

            outputObject = outObj;
            outputObject.UpdatePosition += new ObjectSequence.ObjectPosistionMove(outputObject_UpdatePosition);

            canvas = _ControlHandle.CreateGraphics();
        }
Esempio n. 2
0
 void formFFTSource_FormClosing(object sender, FormClosingEventArgs e)
 {
     if (formFFTSource.isOKButton)
     {
         string selectedObject = formFFTSource.listBoxControlSource.SelectedValue.ToString();
         for (int i = 0; i < tbControlPanelAssignment.Rows.Count; i++)
         {
             if (((ObjectSignal)tbControlPanelAssignment.Rows[i]["control"]).ControlName == selectedObject)
             {
                 OSequence = (ObjectSequence)tbControlPanelAssignment.Rows[i]["control"];
                 break;
             }
         }
         windowType = GetSelectedWindow((ScaledWindowType)Enum.Parse(typeof(ScaledWindowType), formFFTSource.comboBoxEditWindow.SelectedItem.ToString()));
         outputType = formFFTSource.comboBoxEditOutput.SelectedText;
         SequenceSource = OSequence;
     }
 }
        public virtual void Dispose()
        {
            if (controlHandle != null)
            {
                Control controlDispose = controlHandle as Control;
                controlDispose.Dispose();
                controlDispose = null;
            }

            if (sequenceSource != null)
            {
                sequenceSource = null;
            }

            GC.SuppressFinalize(this);
        }
        private void CheckExistingSequenceOutput(ObjectSequence ObSequence)
        {
            List<int> index = new List<int>();
            for (int i = 0; i < TbLineSequence.Rows.Count; i++)
            {
                if (TbLineSequence.Rows[i]["ObjectOut"].ToString() == ObSequence.controlName)
                {
                    index.Add(i);
                }
            }

            if (index.Count > 0)
            {
                for (int i = index.Count - 1; i >= 0; i--)
                {
                    DeleteLineShape(((LineShape)TbLineSequence.Rows[index[i]]["Line"]));
                    TbLineSequence.Rows.RemoveAt(index[i]);
                }
            }
        }