Beispiel #1
0
 /// <summary>
 /// Called when the position of the node is changed.
 /// </summary>
 /// <param name="evtArgs">Event arguments</param>
 /// <remarks>
 /// <para>
 /// This method notifies the
 /// <see cref="Syncfusion.Windows.Forms.Diagram.Port.Parent"/>
 /// of the move by calling the parent node's
 /// <see cref="Syncfusion.Windows.Forms.Diagram.IDispatchNodeEvents.Move"/>
 /// method.
 /// </para>
 /// <seealso cref="Syncfusion.Windows.Forms.Diagram.MoveEventArgs"/>
 /// <seealso cref="Syncfusion.Windows.Forms.Diagram.IDispatchNodeEvents"/>
 /// </remarks>
 protected virtual void OnMove(MoveEventArgs evtArgs)
 {
     if (this.Parent != null)
     {
         IDispatchNodeEvents evtDispatcher = this.Parent.GetService(typeof(IDispatchNodeEvents)) as IDispatchNodeEvents;
         if (evtDispatcher != null)
         {
             evtDispatcher.Move(evtArgs);
         }
     }
 }
Beispiel #2
0
 /// <summary>
 /// Called when the bounds of the node change.
 /// </summary>
 /// <param name="evtArgs">Event arguments</param>
 /// <remarks>
 /// <para>
 /// This method notifies the
 /// <see cref="Syncfusion.Windows.Forms.Diagram.ImageNode.Parent"/>
 /// of the change in bounds by calling the parent node's
 /// <see cref="Syncfusion.Windows.Forms.Diagram.IDispatchNodeEvents.BoundsChanged"/>
 /// method.
 /// </para>
 /// <seealso cref="Syncfusion.Windows.Forms.Diagram.BoundsEventArgs"/>
 /// <seealso cref="Syncfusion.Windows.Forms.Diagram.IDispatchNodeEvents"/>
 /// </remarks>
 protected virtual void OnBoundsChanged(BoundsEventArgs evtArgs)
 {
     if (this.parent != null)
     {
         IDispatchNodeEvents evtDispatcher = this.parent.GetService(typeof(IDispatchNodeEvents)) as IDispatchNodeEvents;
         if (evtDispatcher != null)
         {
             evtDispatcher.BoundsChanged(evtArgs);
         }
     }
 }