/// <summary> /// Raises the navigated to event. /// </summary> /// <param name="navigationParameters">Navigation parameters.</param> public void OnNavigatedTo(IDictionary <string, object> navigationParameters) { #if WINDOWS_PHONE OrientationPage.TouchHandler += HandleTouchHandler; #endif _model.CameraLoading = false; LoadingView.SetBinding(VisualElement.IsVisibleProperty, new Binding("CameraLoading")); _model.CanCapture = CameraView.CameraAvailable; switch (PageOrientation) { case Orientation.Portrait: // set starting focus points for each orientation FocusView.SetFocusPoints(new Point(Width / 2, Height / 2), new Point(Height / 2, Width / 2)); break; case Orientation.LandscapeLeft: case Orientation.LandscapeRight: // set starting focus points for each orientation FocusView.SetFocusPoints(new Point(Height / 2, Width / 2), new Point(Width / 2, Height / 2)); break; } CameraView.NotifyOpenCamera(true); // camera must store these widths for IOS on orientation changes for camera preview layer resizing #if __IOS__ CameraView.NotifyWidths(CAMERA_BUTTON_CONTAINER_WIDTH); #endif this.Show(navigationParameters); }