Ejemplo n.º 1
0
        private void PostProcessInput(object sender, ProcessInputEventArgs e)
        {
            InputReportEventArgs  args;
            RawGenericInputReport report;

            if ((((args = e.StagingItem.Input as InputReportEventArgs) != null) && (args.RoutedEvent == InputManager.InputReportEvent)) && (((report = args.Report as RawGenericInputReport) != null) && !e.StagingItem.Input.Handled))
            {
                GenericEvent     internalEvent = report.InternalEvent;
                GenericEventArgs input         = new GenericEventArgs(this, report.InternalEvent)
                {
                    RoutedEvent = GenericEvents.GenericStandardEvent
                };
                if (report.Target != null)
                {
                    input.Source = report.Target;
                }
                e.PushInput(input, e.StagingItem);
            }
        }
Ejemplo n.º 2
0
 public RawGenericInputReport(PresentationSource inputSource, GenericEvent genericEvent, UIElement destTarget) : base(inputSource, genericEvent.Time)
 {
     this.InternalEvent = genericEvent;
     this.Target        = destTarget;
 }
Ejemplo n.º 3
0
 public GenericEventArgs(InputDevice inputDevice, GenericEvent genericEvent)
     : base(inputDevice, genericEvent.Time) => this.InternalEvent = genericEvent;
Ejemplo n.º 4
0
 public RawGenericInputReport(PresentationSource inputSource, GenericEvent genericEvent) : base(inputSource, genericEvent.Time)
 {
     this.InternalEvent = genericEvent;
     this.Target        = null;
 }