Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Android] Fix Flyout toolbar #18684

Merged
merged 7 commits into from Nov 15, 2023
Merged

[Android] Fix Flyout toolbar #18684

merged 7 commits into from Nov 15, 2023

Conversation

emaf
Copy link
Contributor

@emaf emaf commented Nov 10, 2023

Description of Change

This fix complements fb82b83 to fix toolbar issues when swapping Detail pages. That commit was necessary, but on Android we also need to make sure the Toolbar.Handler is disconnected, otherwise the old toolbar is never removed and we start stacking them.

This was already happening for Window but not for Page . This code is now shared between both to avoid this problem where only one place is changed.

Issues Fixed

Fixes #18050

@emaf emaf requested a review from a team as a code owner November 10, 2023 18:07
Copy link
Member

@PureWeen PureWeen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you move the test created here so that it runs on Android/iOS as well?

I think if we'd originally had that test running on Android/iOS we would have caught this.

Whenever we can apply a test to all three platforms that's ideal!

PureWeen
PureWeen previously approved these changes Nov 14, 2023
emaf and others added 7 commits November 14, 2023 12:47
This fix complements fb82b83 to fix toolbar issues when swapping Detail pages. That commit was necessary, but on Android we also need to make sure the `Toolbar.Handler` is disconnected, otherwise the old toolbar is never removed and we start stacking them.

This was already happening for `Window`  but not for `Page` . This code is now shared between both to avoid this problem where only one place is changed.

Fixes #18050
- Moved test to FlyoutPageTests since it tests both Flyout and Navigation.
- Changed iOS HasBackButton check to check if there is a BackItem, otherwise we were checking for any button in the navigation bar, so it was returning true even for the flyout button.
@PureWeen PureWeen enabled auto-merge (squash) November 14, 2023 22:43
@PureWeen PureWeen merged commit 7168702 into main Nov 15, 2023
47 checks passed
@PureWeen PureWeen deleted the dev/ema/toolbar branch November 15, 2023 01:34
@github-actions github-actions bot locked and limited conversation to collaborators Dec 15, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[regression/8.0.0-preview.5.8529] FlyoutPage Navigation broken in Android
3 participants