예제 #1
0
 /// <summary>
 /// Event handler for tap gesture on dim area
 /// </summary>
 void OnTapped(GestureLayer.TapData data)
 {
     if (IsOpen)
     {
         IsOpen = false;
     }
 }
        private void OnTapStart(GestureLayer.TapData data)
        {
            try
            {
                var properties = BuildProperties(true, false);
                var modifiers  = VirtualKeyModifiers.None;
                var point      = GetPoint(data.X, data.Y);

                _ownerEvents.RaisePointerPressed(
                    new PointerEventArgs(
                        new Windows.UI.Input.PointerPoint(
                            frameId: GetNextFrameId(),
                            timestamp: (uint)data.Timestamp,
                            device: PointerDevice.For(PointerDeviceType.Touch),
                            pointerId: 0,
                            rawPosition: point,
                            position: point,
                            isInContact: properties.HasPressedButton,
                            properties: properties
                            ),
                        modifiers
                        )
                    );
            }
            catch (Exception e)
            {
                this.Log().Error("Failed to raise PointerPressed", e);
            }
        }