# How to hide close player button when controls are not on the screen

**URL:** <https://community.bitmovin.com/t/how-to-hide-close-player-button-when-controls-are-not-on-the-screen/2846>\
**Category:** Support\
**Tags:** bitmovin-player, android, ios, bitmovin\
**Created:** [April 24, 2024, 10:03pm UTC](https://community.bitmovin.com/t/how-to-hide-close-player-button-when-controls-are-not-on-the-screen/2846 "2024-04-24T22:03:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![mykola\_parfenov](https://avatars.discourse-cdn.com/v4/letter/m/a587f6/32.png) [@mykola\_parfenov](https://community.bitmovin.com/u/mykola_parfenov)\
**Post date:** [April 24, 2024, 10:03pm UTC](https://community.bitmovin.com/t/how-to-hide-close-player-button-when-controls-are-not-on-the-screen/2846/1 "2024-04-24T22:03:49Z")

</div>

I have a problem. Since there is no default close icon inside player controls, I added a custom one. But I need to hide it when Bitmovin controls are hidden. Is there any event like onControlsHide/onControlsShow in other video-player react native libraries? So for now it is always on the screen and it is not looking good.

---

<div class="post-metadata">

**Author:** ![roland.kakonyi](https://sea1.discourse-cdn.com/flex015/user_avatar/community.bitmovin.com/roland.kakonyi/32/177_2.png) [@roland.kakonyi](https://community.bitmovin.com/u/roland.kakonyi)\
**Post date:** [April 30, 2024, 2:35pm UTC](https://community.bitmovin.com/t/how-to-hide-close-player-button-when-controls-are-not-on-the-screen/2846/2 "2024-04-30T14:35:56Z")

</div>

Hi @mykola_parfenov!

Thank you for your question!

One option is to customize the player UI itself. It is available open-source here: [GitHub - bitmovin/bitmovin-player-ui: The Bitmovin Adaptive Streaming Player UI](https://github.com/bitmovin/bitmovin-player-ui)

Apparently we already have an example on how to add a close button to the UI:

> <https://github.com/bitmovin/bitmovin-player-ios-samples/blob/2e58bf376fee52613d6dfd5cbbc9745166fc98d6/CustomHtmlUi/Supporting%20Files/customclosebutton.ts>

This is showcased with React Native Example application when using the sample “Custom HTML UI”.  
You can find the code for it here: [bitmovin-player-react-native/example/src/screens/CustomHtmlUi.tsx at development · bitmovin/bitmovin-player-react-native · GitHub](https://github.com/bitmovin/bitmovin-player-react-native/blob/development/example/src/screens/CustomHtmlUi.tsx)
