[.Net10][Proposal][Android] TabbedPage.PopToRootOnTabReselect property #28563
+115
−0
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of Change
This PR introduces a new Android platform specific called
TabbedPage.PopToRootOnTabReselectProperty
in .NET MAUI TabbedPage. This property allows developers to control whether reselecting the currently active tab should automatically pop its navigation stack to the root page.On iOS, this behavior is already the default, but on Android, tabs retain their navigation stack when reselected. This property provides a way to align Android’s behavior with iOS, ensuring a consistent user experience across platforms.
Motivation
In many tab-based applications, users expect that tapping an already selected tab should reset its navigation stack, bringing them back to the root of that section. Currently, this behavior must be manually implemented with lots of additional workarounds. This property provides a built-in way to achieve this functionality, improving developer experience and reducing boilerplate code.
Demo
Screen.Recording.2025-03-22.at.16.11.40.mov
Screen.Recording.2025-03-22.at.16.16.45.mov
Usage
Issues Fixed
Fixes #27401
Fixes #15301