private async void OnPageClosing()
        {
            try
            {
                // Delete last saved temp file when user taps on "Share" button (this will contain the zip file path if the shared document
                // format is SVG, since it doesn't support multipage and the document will be virtual document that consists of multiple documents).
                if (!string.IsNullOrWhiteSpace(_tempFileToDeleteAfterShare) && File.Exists(_tempFileToDeleteAfterShare))
                {
                    File.Delete(_tempFileToDeleteAfterShare);
                }
            }
            catch (Exception) { }

            _documentViewer.View.ImageViewer.ScrollOffsetChanged -= ImageViewer_ScrollOffsetChanged;

            // Prevent double-tapping
            PageBackButton.IsEnabled = false;

            // Cancel speeck (if playing)
            CancelSpeech();

            PageClosing?.Invoke(this, null);

            // Go back
            await PopupNavigation.Instance.PopAsync();
        }
 public void OnClose()
 {
     if (EditContext?.Validate() == true)
     {
         PageClosing?.Invoke(EditContext);
     }
 }
        private async void OnPageClosing()
        {
            DeselectAllCards();

            PageClosing?.Invoke(this, null);

            await PopupNavigation.Instance.PopAsync();
        }
        private async void OnPageClosing(bool closePage = true)
        {
            PageClosing?.Invoke(this, null);

            if (closePage)
            {
                await PopupNavigation.Instance.PopAsync();
            }
        }
        private async void OnPageClosing()
        {
            PageClosing?.Invoke(this, null);

            carouselView.ItemsSource = null;
            backImageContainer.Children.Clear();
            addBackImageContainer.Children.Clear();
            this.BindingContext = null;

            // Check if this card was deleted inside the UpdateBusinessCardPage, then we already popped this page out.
            if (HomePage.ContactCollection.Contains(ContactItem))
            {
                await PopupNavigation.Instance.PopAsync();
            }
        }
Esempio n. 6
0
        private async void BackButton_Tapped(object sender, EventArgs e)
        {
            // Prevent double-tapping
            BackButton.IsEnabled = false;

            PageClosing?.Invoke(this, null);

            if (CanClosePage)
            {
                // Go back
                await PopupNavigation.Instance.PopAsync();
            }
            else
            {
                BackButton.IsEnabled = true;
            }
        }
Esempio n. 7
0
        private async void OnPageClosing()
        {
            // Delete last saved temp file when user tapped on "Export" button.
            if (!string.IsNullOrWhiteSpace(_tempOutputFilePath) && _documentPath.CompareTo(_tempOutputFilePath) != 0)
            {
                File.Delete(_tempOutputFilePath);
            }

            _documentViewer.View.ImageViewer.ScrollOffsetChanged -= ImageViewer_ScrollOffsetChanged;

            // Prevent double-tapping
            PageBackButton.IsEnabled = false;

            // Cancel speeck (if playing)
            CancelSpeech();

            PageClosing?.Invoke(this, null);

            // Go back
            await PopupNavigation.Instance.PopAsync();
        }
Esempio n. 8
0
 private async void OnPageClosing(RasterImage image)
 {
     StopCamera();
     PageClosing?.Invoke(this, new CameraPageClosingEventArgs(image));
     await PopupNavigation.Instance.PopAsync();
 }
Esempio n. 9
0
 public void OnPageClosing()
 {
     PageClosing?.Invoke(this, new EventArgs());
 }
 private void DocumentConverterPage_Disappearing(object sender, EventArgs e)
 {
     PageClosing?.Invoke(this, _pageClosingEventArgs);
 }
Esempio n. 11
0
 public void OnPageClosing()
 {
     Logger.Trace();
     PageClosing?.Invoke(this, new EventArgs());
 }