summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--android-mobile/AndroidManifest.xml4
-rw-r--r--android-mobile/res/drawable/splash.xml12
-rw-r--r--android-mobile/res/drawable/subsurface_mobile_splash.9.pngbin0 -> 95837 bytes
-rw-r--r--android-mobile/res/values/apptheme.xml6
-rw-r--r--qt-mobile/qml/main.qml20
5 files changed, 40 insertions, 2 deletions
diff --git a/android-mobile/AndroidManifest.xml b/android-mobile/AndroidManifest.xml
index f900cc55a..e598303d0 100644
--- a/android-mobile/AndroidManifest.xml
+++ b/android-mobile/AndroidManifest.xml
@@ -14,6 +14,7 @@
android:name="org.qtproject.qt5.android.bindings.QtActivity"
android:configChanges="orientation|uiMode|screenLayout|screenSize|smallestScreenSize|locale|fontScale|keyboard|keyboardHidden|navigation"
android:label="@string/app_name"
+ android:theme="@style/AppTheme"
android:launchMode="singleTop"
android:screenOrientation="unspecified" >
<intent-filter>
@@ -77,7 +78,8 @@
<!-- Splash screen -->
- <meta-data android:name="android.app.splash_screen_drawable" android:resource="@drawable/subsurface_mobile_splash" />
+<!-- <meta-data android:name="android.app.splash_screen_drawable" android:resource="@drawable/subsurface_mobile_splash" /> -->
+ <meta-data android:name="android.app.splash_screen_drawable" android:resource="@drawable/splash" />
<!-- Splash screen -->
</activity>
diff --git a/android-mobile/res/drawable/splash.xml b/android-mobile/res/drawable/splash.xml
new file mode 100644
index 000000000..a27a22df4
--- /dev/null
+++ b/android-mobile/res/drawable/splash.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
+ <item>
+ <shape android:shape="rectangle" >
+ <solid android:color="#000000FF"/>
+ </shape>
+ </item>
+ <item>
+ <bitmap android:src="@drawable/subsurface_mobile_splash"
+ android:gravity="center" />
+ </item>
+</layer-list>
diff --git a/android-mobile/res/drawable/subsurface_mobile_splash.9.png b/android-mobile/res/drawable/subsurface_mobile_splash.9.png
new file mode 100644
index 000000000..575b300cd
--- /dev/null
+++ b/android-mobile/res/drawable/subsurface_mobile_splash.9.png
Binary files differ
diff --git a/android-mobile/res/values/apptheme.xml b/android-mobile/res/values/apptheme.xml
new file mode 100644
index 000000000..adec2328c
--- /dev/null
+++ b/android-mobile/res/values/apptheme.xml
@@ -0,0 +1,6 @@
+<?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>
diff --git a/qt-mobile/qml/main.qml b/qt-mobile/qml/main.qml
index bcbc310f1..b2c94f4f4 100644
--- a/qt-mobile/qml/main.qml
+++ b/qt-mobile/qml/main.qml
@@ -17,7 +17,8 @@ MobileComponents.ApplicationWindow {
id: fontMetrics
}
- visible: true
+ visible: false
+ opacity: 0
globalDrawer: MobileComponents.GlobalDrawer {
title: "Subsurface"
@@ -200,6 +201,14 @@ MobileComponents.ApplicationWindow {
initialPage: DiveList {
anchors.fill: detailsPage
id: diveDetails
+ opacity: 0
+ Behavior on opacity {
+ NumberAnimation {
+ duration: 200
+ easing.type: Easing.OutQuad
+ }
+ }
+
}
QMLManager {
@@ -244,5 +253,14 @@ MobileComponents.ApplicationWindow {
Component.onCompleted: {
manager.finishSetup();
+ rootItem.visible = true
+ diveDetails.opacity = 1
+ rootItem.opacity = 1
+ }
+ Behavior on opacity {
+ NumberAnimation {
+ duration: 200
+ easing.type: Easing.OutQuad
+ }
}
}