Skip to content

Satellite tracker and pass predictor for Android, inspired by Gpredict

Restored the splash theme/screen

Arty Bishop64357697bd37
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index 87c070f5..ce0c970b 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -33,7 +33,8 @@
android:theme="@style/AppTheme">
<activity
android:name=".ui.activities.MainActivity"
- android:screenOrientation="portrait">
+ android:screenOrientation="portrait"
+ android:theme="@style/AppTheme.Splash">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
diff --git a/app/src/main/java/com/rtbishop/look4sat/ui/activities/MainActivity.kt b/app/src/main/java/com/rtbishop/look4sat/ui/activities/MainActivity.kt
index cc8b5f94..3cc05ef3 100644
--- a/app/src/main/java/com/rtbishop/look4sat/ui/activities/MainActivity.kt
+++ b/app/src/main/java/com/rtbishop/look4sat/ui/activities/MainActivity.kt
@@ -12,6 +12,7 @@ import dagger.hilt.android.AndroidEntryPoint
class MainActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
+ setTheme(R.style.AppTheme)
super.onCreate(savedInstanceState)
val binding = ActivityMainBinding.inflate(layoutInflater)
setContentView(binding.root)
diff --git a/app/src/main/res/drawable-nodpi/splash_front.webp b/app/src/main/res/drawable-nodpi/splash_front.webp
new file mode 100644
index 00000000..c694aa09
Binary files /dev/null and b/app/src/main/res/drawable-nodpi/splash_front.webp differ
diff --git a/app/src/main/res/drawable/splash_drawable.xml b/app/src/main/res/drawable/splash_drawable.xml
new file mode 100644
index 00000000..34e5c42b
--- /dev/null
+++ b/app/src/main/res/drawable/splash_drawable.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?><!--
+ ~ Look4Sat. Amateur radio and weather satellite tracker and passes predictor for Android.
+ ~ Copyright (C) 2019, 2020 Arty Bishop ([email protected])
+ ~
+ ~ This program is free software; you can redistribute it and/or modify
+ ~ it under the terms of the GNU General Public License as published by
+ ~ the Free Software Foundation; either version 2 of the License, or
+ ~ (at your option) any later version.
+ ~
+ ~ This program is distributed in the hope that it will be useful,
+ ~ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ ~ GNU General Public License for more details.
+ ~
+ ~ You should have received a copy of the GNU General Public License along
+ ~ with this program; if not, write to the Free Software Foundation, Inc.,
+ ~ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ -->
+
+<layer-list xmlns:android="http://schemas.android.com/apk/res/android"
+ android:opacity="opaque">
+ <item android:drawable="@drawable/ic_launcher_background" />
+ <item>
+ <bitmap
+ android:gravity="center"
+ android:src="@drawable/splash_front" />
+ </item>
+</layer-list>
diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml
index 76fbc9e1..38c67bcc 100644
--- a/app/src/main/res/values/styles.xml
+++ b/app/src/main/res/values/styles.xml
@@ -26,6 +26,10 @@
<item name="android:statusBarColor">@android:color/transparent</item>
</style>
+ <style name="AppTheme.Splash" parent="AppTheme">
+ <item name="android:windowBackground">@drawable/splash_drawable</item>
+ </style>
+
<style name="TopBar">
<item name="android:layout_width">match_parent</item>
<item name="android:layout_height">48dp</item>