Skip to content

Instantly share code, notes, and snippets.

@DamianSuess
Last active September 9, 2016 17:17
Show Gist options
  • Save DamianSuess/2b8b77b3d9a845b51b5558717782e1b7 to your computer and use it in GitHub Desktop.
Save DamianSuess/2b8b77b3d9a845b51b5558717782e1b7 to your computer and use it in GitHub Desktop.
Android - Remove Title and Notification bars
namespace TestApp.Droid
{
[Activity(Label = "myApp",
MainLauncher = true,
Icon = "@drawable/Icon",
ScreenOrientation = ScreenOrientation.Landscape)]
public class MainActivity : global::Xamarin.Forms.Platform.Android.FormsAppCompatActivity
{
protected override void OnCreate(Bundle bundle)
{
//Remove title bar
RequestWindowFeature(WindowFeatures.NoTitle);
//Remove notification bar
Window.SetFlags(WindowManagerFlags.Fullscreen, WindowManagerFlags.Fullscreen);
// ... Other init code goes here ...
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment