Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- getWindow().setFlags(WindowManager.LayoutParams.FLAG_LAYOUT_IN_SCREEN,WindowManager.LayoutParams.FLAG_FULLSCREEN);
- protected void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- getWindow().requestFeature(Window.FEATURE_ACTION_BAR);
- getActionBar().hide();
- setContentView(R.layout.test_activity);
- <activity
- android:name=".activity.SplashActivity"
- android:screenOrientation="portrait"
- android:theme="@android:style/Theme.NoTitleBar.Fullscreen" >
- <intent-filter>
- <action android:name="android.intent.action.MAIN" />
- <category android:name="android.intent.category.LAUNCHER" />
- </intent-filter>
- </activity>
- <style name="SplashTheme" parent="Theme.AppCompat.NoActionBar">
- <item name="colorPrimary">@color/colorPrimary</item>
- <item name="colorPrimaryDark">@color/colorPrimary</item>
- <item name="colorAccent">@color/colorAccent</item>
- <item name="android:windowBackground">@color/colorPrimary</item>
- </style>
- <activity
- android:name=".ActivityName"
- android:theme="@style/SplashTheme"> // apply splash them here
- <intent-filter>
- <action android:name="android.intent.action.MAIN" />
- <category android:name="android.intent.category.LAUNCHER" />
- </intent-filter>
- </activity>
Add Comment
Please, Sign In to add comment