benlau/quickandroid

splash screen - minor issue

Opened this issue · 2 comments

I have observed a minor jerk in the position of logo in the splash screen of the example
app quickandroidexample
I tried using the sample concept as described by you in
https://medium.com/@benlaud/complete-guide-to-make-a-splash-screen-for-your-qml-android-application-567ca3bc70af in a separate app and faced the same issue.

I think even quickandroidexample uses the same concept.
on my investigation i feel that the issue is that
the theme draws the splash screen once as:

apptheme.xml is

<?xml version="1.0" encoding="utf-8"?>
<resources>
    <style name="AppTheme" parent="@android:style/Theme.DeviceDefault.Light.NoActionBar">
        <item name="android:windowBackground">@drawable/splash</item>
    </style>
</resources>

and the instruction in AndroidManifest.xml also makes it draws once because of

  <!-- Splash screen -->
<meta-data android:name="android.app.splash_screen_drawable" 
android:resource="@drawable/splash"/>
  <!-- Splash screen -->

And both of them do not place the logo at exactly the same place.

Thanks for quickandroid .

regds
Rajesh Kumar Mallah.

yes, I also find this issue. I didn't go in deep to find out the main reason. But that could be avoided if the splash screen load in full screen mode.

For example,

<?xml version="1.0" encoding="utf-8"?>
<resources>
    <style name="AppTheme" parent="@android:style/Theme.Black.NoTitleBar">
        <item name="android:windowBackground">@drawable/splash</item>
        <item name="android:colorBackground">@color/black</item>
        <item name="android:windowFullscreen">true</item>
    </style>
</resources>

Ofcoz, it may need to set back to non-fullscreen for your application.