private async void OnNext()
        {
            try
            {
                var croppedImage = await _cropControl.GetCroppedImage();

                _navigationFacade.NavigateToUploadView(croppedImage, Category);
            }
            catch (Exception)
            {
                await _dialogService.ShowNotification("CroppingError_Message", "GenericError_Title");
            }
        }
        private async void OnTakePhoto()
        {
            try
            {
                IsBusy = true;

                var photo = await _cameraEngine.TakePhoto();

                _navigationFacade.NavigateToUploadView(photo, Category);
            }
            finally
            {
                IsBusy = false;
            }
        }
        private async void OnNext()
        {
            try
            {
                _telemetryClient.TrackEvent(TelemetryEvents.NextCommandInvoked);
                var croppedImage = await _cropControl.GetCroppedImage();

                _navigationFacade.NavigateToUploadView(croppedImage, Category);
            }
            catch (Exception e)
            {
                _telemetryClient.TrackException(e);
                await _dialogService.ShowNotification("CroppingError_Message", "GenericError_Title");
            }
        }
        private async void OnTakePhoto()
        {
            try
            {
                var startTime = DateTime.Now;
                _telemetryClient.TrackEvent("Camera triggered");

                IsBusy = true;
                var photo = await _cameraEngine.TakePhoto();

                _navigationFacade.NavigateToUploadView(photo, Category);

                var timeTaken = DateTime.Now - startTime;
                _telemetryClient.TrackEvent("Photo taken", null, new Dictionary <string, double>
                {
                    { TelemetryProperties.TotalTimeToTakePhoto, timeTaken.TotalMilliseconds }
                });
            }
            finally
            {
                IsBusy = false;
            }
        }
Exemple #5
0
 private void OnEditPhoto()
 {
     _navigationFacade.NavigateToUploadView(Photo, Category.ToCategory());
 }