public void AccessibilityDoGestureSignalGetSizeOfGestureInfo() { tlog.Debug(tag, $"AccessibilityDoGestureSignalGetSizeOfGestureInfo START"); uint size = AccessibilityDoGestureSignal.GetSizeOfGestureInfo(); tlog.Debug(tag, $"size={size}"); Assert.IsNotNull(size, "should be not null"); tlog.Debug(tag, $"AccessibilityDoGestureSignalGetSizeOfGestureInfo END (OK)"); }
private void OnAccessibilityGestureInfoEvent(IntPtr data) { if (data == IntPtr.Zero) { return; } if (Marshal.SizeOf <GestureInfoType>() != AccessibilityDoGestureSignal.GetSizeOfGestureInfo()) { throw new global::System.ApplicationException("ABI mismatch SizeOf(C# GestureInfo) != SizeOf(c++ GestureInfo)"); } var arg = new GestureInfoEventArgs(); arg.Consumed = AccessibilityDoGestureSignal.GetResult(data); arg.GestureInfo = (GestureInfoType)Marshal.PtrToStructure(data, typeof(GestureInfoType)); gestureInfoHandler?.Invoke(this, arg); AccessibilityDoGestureSignal.SetResult(data, Convert.ToInt32(arg.Consumed)); }