public void Detach(FrameworkElement view) { if (view is WindowsFormsHost wfh) { winforms.Detach(wfh.Child); } else { element.Detach(view); } element = null; winforms = null; }
public SKTouchHandler(Action <SKTouchEventArgs> onTouchAction, Func <double, double, SKPoint> scalePixels) { element = new SKTouchHandlerElement(onTouchAction, scalePixels); winforms = new SKTouchHandlerWinForms(onTouchAction, scalePixels); }