Frage

I am developing an android app using phonegap (cordova-2.1.0).

My MainActivity.java code is as following -

package com.app.myapp;

import android.os.Bundle;
import org.apache.cordova.*;

public class MainActivity extends DroidGap {
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        super.loadUrl("file:///android_asset/www/index.html");
    }
}

Problem : Whenever I start the application, it shows MainActivity window first and then show the actual HTML code. Is there any way to get rid of MainActivity and show the HTML directly?

Thanks in Advance...

War es hilfreich?

Lösung

Add this to your AndroidManifest application tag:

android:theme="@android:style/Theme.NoTitleBar"

Should do the trick.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top