Skip to content

pavan142/FullScreenExperiments

Repository files navigation

An android application with collapsible navigation bars for a full screen activity

There is also a medium article written by me on this same thing. https://pa1tirumani.medium.com/how-to-get-your-activity-to-occupy-full-screen-on-android-9df99b641185

Introduction

The Visibility flags that are employed in achieving various levels of full screen activity

  • SYSTEM_UI_FLAG_FULLSCREEN: Hide the status bar
  • SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN: Let the layout expand into status bar
  • SYSTEM_UI_FLAG_LAYOUT_STABLE: Avoid abrupt layout changes during toggling of status and navigation bars
  • SYSTEM_UI_FLAG_HIDE_NAVIGATION: Hide the navigation bar
  • SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION;: Let the layout expand into navigation bar

The Theme Attributes employed in achieving various levels of full screen activity

  • windowActionBar: Set to false to remove the action bar
  • windowNoTitle: Set to true to remove the annoying window title
  • android:windowLayoutInDisplayCutoutMode: Set to shortEdges to let the layout expand to the front camera notch in both portrait and landscape modes

I have added the commits sequentially increasing the level of full screeness. You can track the corresponding changes and their effects below

Removal of Action Bar

Removal of Status Bar

Expansion to Status Bar

Removal of Navigation Bar

Toggle Visibility of Bars

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages