、あなただけのそれに応じてサイズを変更し、各画面サイズのために、このような描画可能なファイルを作成する必要があります(このexempleが中央に画像とグラデーション背景が表示されます)
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<gradient
android:startColor="#2b3143"
android:centerColor="#37465e"
android:endColor="#55647c"
android:angle="135"/>
</shape>
</item>
<item>
<bitmap
android:gravity="center"
android:src="@drawable/myCuteLogo"/>
</item>
そして、SplashActivを作成
<style name="SplashScreenStyle" parent="myAppTheme">
<item name="android:windowBackground">@drawable/splash_screen</item>
</style>
:あなたは、スタイルを作成し、作成した描画可能とプロパティandroid:windowBackground
を設定
スプラッシュ画面が表示されますITY:
public class SplashScreen extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Intent intent = new Intent(this, Activity_a_Main.class);
startActivity(intent);
finish();
}}
あなたのマニフェストの最後にはLancher活動としてSplashActivityを設定し、作成したスタイルにそのテーマを設定:
<activity android:name=".Activities.SplashScreen"
android:theme="@style/SplashScreenStyle">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
私はこれがあなた
を役に立てば幸い
注:作成したスタイルをアプリケーション全体のテーマとして設定すると、ソフトキーボードの背景など、奇妙な場所にドロワブルが表示されます
レイアウトを作成しましたか?大型の大型スクリーン? – Stanojkovic