1
0
Fork 0

Add better loading screen (#4)

* Add loading, including a spinner, and the default discord background color.

* Add light mode support.
This commit is contained in:
Henry Hiles 2022-12-18 16:00:56 -05:00 committed by GitHub
parent 2ebc0fecc4
commit 48e84f8e93
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 29 additions and 7 deletions

View file

@ -1,13 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<android.widget.LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
<android.widget.RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity">
<ProgressBar android:indeterminate="true" android:layout_width="40dp"
android:layout_height="40dp" android:layout_centerInParent="true" />
<WebView
android:id="@+id/webview"
android:layout_width="match_parent"
android:layout_height="match_parent"
/>
</android.widget.LinearLayout>
android:visibility="invisible" />
</android.widget.RelativeLayout>

View file

@ -0,0 +1,2 @@
<?xml version="1.0" encoding="utf-8"?>
<resources><color name="background">#363942</color></resources>

View file

@ -0,0 +1,2 @@
<?xml version="1.0" encoding="utf-8"?>
<resources><color name="background">#FFFFFF</color></resources>

View file

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="LoadingTheme" parent="@android:style/Theme.Material.Light.NoActionBar">
<item name="android:windowBackground">@color/background</item>
</style>
</resources>