Skip to content

Instantly share code, notes, and snippets.

@gsrathoreniks
Last active February 6, 2020 07:29
Show Gist options
  • Save gsrathoreniks/34969fd1b3c738ea47d5fd7070abe556 to your computer and use it in GitHub Desktop.
Save gsrathoreniks/34969fd1b3c738ea47d5fd7070abe556 to your computer and use it in GitHub Desktop.
1. Add this to STYLE.XML
<style name="SplashTheme" parent="Theme.AppCompat.NoActionBar">
<item name="android:windowBackground">@drawable/launch</item>
</style>
__________________________________________________________________________
2. Add launch.xml file in {res --> drawable}
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<!--<item>-->
<!--<bitmap-->
<!--android:gravity="center"-->
<!--android:src="@drawable/ic_milk_products"/>-->
<!--</item>-->
<item>
<bitmap
android:gravity="fill"
android:src="@drawable/splash_back_image"/>
</item>
</layer-list>
__________________________________________________________________________
3. Add "splash_back_image" in the { res ---> drawable } folder
__________________________________________________________________________
4. Add "ORIENTATION" & "THEME" to the MANIFEST
.
.
.
.
.
DONE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment