-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
6.8.4, 6.9.2, 6.10.0 Beta4
-
None
If a user sets a splash screen theme for the QtActivity in the manifest
<activity android:name="org.qtproject.qt.android.bindings.QtActivity" ... android:theme="@style/splashScreenTheme">
Then if the user wants to override that theme, for example to avoid its background color showing under the other windows that are not taking the whole screen size. Atm, one can do that by calling setTheme() from own Activity:
package my.package.name; import android.os.Bundle; import org.qtproject.qt.android.bindings.QtActivity; public class MyActivity extends QtActivity { @Override public void onCreate(Bundle savedInstanceState) { // must be before super.onCreate(), otherwise overriding the theme will not work setTheme(Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q ? android.R.style.Theme_DeviceDefault_DayNight : android.R.style.Theme_Holo_Light); super.onCreate(savedInstanceState); } }
Doing this would set the new theme and override the splash screen theme, however, on many devices and depending on the app, there could be a short noticeable time where the app is just a blank screen that has nothing rendered.
So atm reseting the theme this way, is not a proper solution and we need to figure out whether we can delay setting the new theme until the Qt content is ready so we don't end up in this situation.