/// Determines the behavior of pinch gesture. private void OnPinchGestureDetected(object source, PinchGestureDetector.DetectedEventArgs e) { if (e == null) { return; } if (e.PinchGesture.State == Gesture.StateType.Started) { preScale = e.PinchGesture.Scale; } else if (e.PinchGesture.State == Gesture.StateType.Finished || e.PinchGesture.State == Gesture.StateType.Cancelled) { if (preScale > e.PinchGesture.Scale) { if (BorderWindow.IsMaximized()) { BorderWindow.Maximize(false); } else { BorderWindow.Minimize(true); } } else { BorderWindow.Maximize(true); } } }
public virtual bool OnMinimizeIconTouched(object sender, View.TouchEventArgs e) { if (e == null) { return(false); } if (e.Touch.GetState(0) == PointStateType.Up) { ClearWindowGesture(); BorderWindow.Minimize(true); } return(true); }
protected void MinimizeBorderWindow() { ClearWindowGesture(); BorderWindow.Minimize(true); OnMinimize(true); }