Forum Archive

Hide close button UI

Webmaster4o

I'd like a way to keep my right_button_items but hide the close button. Is there an easy way to do this? The only way I can think is to encompass everything in a NavigationView, then hide the title bar of the main view. This seems silly, and kind of hackish

Phuket2

@Webmaster4o , have never tried hiding or modififying the visible attribute of the left or right buttonItems. If you hide the menu bar write your own , you would have full control. But, it would be worth trying to write a function or method to dynamically to add and delete the UI.ButtonItem.

Phuket2

I just did a dir on UI.Button and UI.ButtonItem. ui.ButtonItem() has an enabled attr. Not sure if that helps you vrs hiding it

omz

There isn't really a good way to do this except for putting everything into your own NavigationView.

Webmaster4o

Ok, thanks @omz. I ended up just hiding the title bar and placing my button elsewhere in the UI.