Tinkr2/4.2/AphelionCore/AphelionCommonControls/Controls/Containers/Panel.cs
/// <summary>
/// Override this message to handle touch events internally.
/// </summary>
/// <param name="sender">Object sending the event</param>
/// <param name="point">Point on screen touch event is occurring</param>
/// <param name="handled">true if the event is handled. Set to true if handled.</param>
/// <remarks>
/// Forwards the message to the top most child under the point.
/// The hit child is made the active child.
/// </remarks>
Override this message to handle touch events internally.
Override this message to handle touch events internally .
protected override void TouchDownMessage(object sender, point point, ref bool handled)
      {
         if (Children != null)
         {
            lock (Children)
            {
               for (int i = Children.Length - 1; i >= 0; i--)
               {
                  if (Children[i].Visible && Children[i].HitTest(point))
                  {
                     ActiveChild = Children[i];
                     Children[i].SendTouchDown(this, point);
                     handled = true;
                     return;
                  }
               }
            }
         }
         if (ActiveChild != null)
         {
            ActiveChild.Blur();
            Render(ActiveChild.ScreenBounds, true);
            ActiveChild = null;
         }
         _touch = true;
      }
protected override void TouchDownMessage ( object sender , point point , ref bool handled ) { if ( Children != null ) { lock ( Children ) { for ( int i = Children . Length - 1 ; i >= 0 ; i -- ) { if ( Children [ i ] . Visible && Children [ i ] . HitTest ( point ) ) { ActiveChild = Children [ i ] ; Children [ i ] . SendTouchDown ( this , point ) ; handled = true ; return ; } } } } if ( ActiveChild != null ) { ActiveChild . Blur ( ) ; Render ( ActiveChild . ScreenBounds , true ) ; ActiveChild = null ; } _touch = true ; }
Override this message to handle touch events internally.
Override this message to handle touch events internally .
//TODO: check if this code shouldn't go to Container // Check Controls
sender
object
Object sending the event
Object sending the event
point
point
Point on screen touch event is occurring
Point on screen touch event is occurring
bool
ref
handled
true if the event is handled. Set to true if handled.
true if the event is handled . Set to true if handled .
remarks
Forwards the message to the top most child under the point.
The hit child is made the active child.
Forwards the message to the top most child under the point . The hit child is made the active child .