4

I'm coding an Android app through Phonegap and I'm at the point of installing the Splashscreen.

I managed to install a landscape splashscreen using this question, but as I expected it doesn't recognize it as a landscape or portrait splashscreen, so it just displays the image, no matter the orientation of the device. How do I tell it should show the wide image when the device is in landscape and the high image when the device is in portrait mode?

I'm using:
- Eclipse
- Phonegap 1.5.0

Edit: Question updated! See text below. Thanks to ghostCoder I got one step closer, but it still doesn't work.

Do I have to add something to the following code to draw the portrait images? (it still displays the landscape, no matter the orientation of the device)

@Override
    public void onCreate(Bundle savedInstanceState)
    {
        super.onCreate(savedInstanceState);
        super.setIntegerProperty("splashscreen", R.drawable.splash);
        super.loadUrl("file:///android_asset/www/index.html");
    }
}

This is how my folders look now: folders in res folder

Community
  • 1
  • 1
Rvervuurt
  • 8,589
  • 8
  • 39
  • 62

1 Answers1

7

have the folder structure of the res folder like this. now u can have the splash screen of landscape in the 'land' folders and of the portrait mode in folders without land. hope this helps.

enter image description here

ghostCoder
  • 1
  • 9
  • 49
  • 72