Rg.Plugins.Popup icon indicating copy to clipboard operation
Rg.Plugins.Popup copied to clipboard

[UWP] Pressing back button navigates the page behind backwards (Prism 7.2)

Open BurkusCat opened this issue 4 years ago • 3 comments

🐛 Bug Report

I am using Prism 7.2, Xamarin.Forms 4.8, and trying to use Rg.Plugins.Popup on UWP. If I navigate through a few pages and then open up a popup. The back button is still available. When I press the back button, the page behind the popup navigates backwards. The popup remains open.

In the pop up, I am trying to have the back button press be ignored:

        protected override bool OnBackButtonPressed()
        {
            // Return true if you don't want to close this popup page when a back button is pressed
            return true;
        }

This stops the popup from closing, but the page behind the popup still navigates backwards.

Expected behavior

Popup should stay open. Page behind should not navigate backwards. The UWP back button should either do nothing or not be visible.

Reproduction steps

  • Have a flyout page
  • Navigate through a few pages
  • Press a button that opens up a popup using Prism navigation
  • Press the UWP back button
  • Observe that the page behind the popup navigates backwards

Configuration

Version: 2.0.0.9

Platform:

  • [ ] :iphone: iOS
  • [ ] :robot: Android
  • [ ] :checkered_flag: WPF
  • [x] :earth_americas: UWP
  • [ ] :apple: MacOS
  • [ ] :tv: tvOS
  • [x] :monkey: Xamarin.Forms

BurkusCat avatar Jan 13 '21 14:01 BurkusCat

Can report the same issue

anpin avatar Jan 21 '21 17:01 anpin

hey @BurkusCat sorry for an admittedly VERY late reply, I don't have a UWP environment setup.

Can you reproduce this issue without using Prism? Such as within the Demo Environment

LuckyDucko avatar May 04 '21 06:05 LuckyDucko

Hey @LuckyDucko, I am no longer working on the project that needed this fix. If I am working on the project again later this year, I will put together a repro project.

Thanks, Ronan

BurkusCat avatar May 04 '21 14:05 BurkusCat