LaunchActivity 未显示正确的布局

LaunchActivity not displaying correct layout

我有一个使用此布局的发射 activity,它仅在中心显示图像。

但是只显示空白的黑页,然后跳转到目标class。

问题是启动 activity 与 activity_launch.xml 中显示的不一样...有什么问题?

activity_launch.xml:

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
tools:context=".app.LaunchActivity"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:gravity="center_vertical|center_horizontal"
android:background="#0064B0">

<ImageView
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:src="@drawable/logo_property_finder" />
</LinearLayout>

Java:

public class LaunchActivity extends BaseActivity {

@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_launch);

    try {
        Thread.sleep(1000);
    } catch (InterruptedException e) {
        e.printStackTrace();
    } finally {
        Intent intent = new Intent(this, HomeActivity.class);
        startActivity(intent);
        this.finish();
    }
}
}

这是 LaunchActivity 的清单: 清单:

<application
    android:name=".app.BaseApplication"
    android:allowBackup="true"
    android:icon="@drawable/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/MyTheme">

    <!-- App Pages -->
    <activity
        android:name=".app.LaunchActivity"
        android:label="@string/app_name"
        android:launchMode="singleTop"
        android:screenOrientation="portrait"
        android:theme="@android:style/Theme.Holo.NoActionBar.Fullscreen" >
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
... Other activities
</application>

我的主题:

<style name="MyTheme" parent="@android:style/Theme.Holo.Light">
    <item name="android:homeAsUpIndicator">@drawable/button_back</item>
    <item name="android:actionBarStyle">@style/MyActionBar</item>
</style>

在 LaunchActivity 的 onCreate() 方法中这样尝试。

Handler handler=new Handler();
    handler.postDelayed(new Runnable() {

        @Override
        public void run() {
            Intent intent=new Intent(LaunchActivity.this, HomeActivity.class);
            startActivity(intent);
            finish();
        }
    }, 1000);