Closed Paul-Brenner-Tangoe closed 2 years ago
The way we wrap the Page inside another ViewController when pushing on UIViewControlelr will not allow this to work.
This is could be done with a platform specific for iOS, i will set this as a enhancememnt
@rmarinho I suppose you mean updating ParentingViewController
's property before pushing the page on the stack?
yeah that was the wrapper I was referring , but remember this is internal, we could change that ..
What did you mean by "we could change that"? You mean we could get rid of the wrapper, make it non-internal, or something else?
The way we wrap the Page inside another ViewController when pushing on UIViewControlelr will not allow this to work.
Thank you @rmarinho for this hint, as a workaround I'm now using a custom renderer (in Xamarin.Forms) with:
public override void DidMoveToParentViewController(UIViewController parent)
{
base.DidMoveToParentViewController(parent);
// hide bottom tabbar
parent.HidesBottomBarWhenPushed = true;
}
And it's working, however it leaves an extra transparent space at the bottom (with the height of the hidden tabbar) which I don't know how to remove. I think it might be caused by the child view not scaling up with the wrapper.
I'm neither a Xamarin nor an iOS dev expert, do you have any suggestions to resolve it?
Sorry for bothering and thanks in advance.
Thanks for this suggestion! As Xamarin.Forms is now in maintenance mode, this will not happen anymore for Xamarin.Forms. We're only adding bugfixes and stability fixes.
If this is still important to you, make sure to check the .NET MAUI repo and see if it's already on the roadmap. If not, feel free to open a discussion to discuss a change first or open an issue with a detailed feature request. Thanks!
Bug report best practices: https://github.com/xamarin/Xamarin.Forms/wiki/Submitting-Issues
Description
Migrating https://bugzilla.xamarin.com/show_bug.cgi?id=56072 here
I have a tabbed page with a page and a page in a navigation controller. On the page with the navigation controller, there is a button that will do a push to another page. When the page is pushed I want to remove the tab bar. And when the user hits back, I want the tab bar to reappear. The property HidesBottomBarWhenPushed on a UIViewController is supposed to do just that.
Setting that property in a Xamarin.ios project works perfectly, does exactly what it is supposed to do.
Setting the property in a custom renderer in a Xamarin.forms project does nothing, the tab bar won't disappear when the page is pushed.
Steps to Reproduce
Expected Behavior
The tabbar disappears when you use the button to navigate
Actual Behavior
The tabbar does not disappear
Basic Information
Reproduction Link
https://www.dropbox.com/s/0h9az4ybpag12tm/hidesbottombarwhenpushedxam.zip?dl=0 The attached zip has the Xamarin.ios project as well as the Xamarin forms project.