Skip to content
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@
android:launchMode="singleTask"
android:name="com.fpvout.digiview.MainActivity"
android:screenOrientation="sensorLandscape"
android:configChanges="orientation|keyboardHidden">
android:configChanges="orientation|keyboardHidden"
android:theme="@style/Theme.DigiviewStartup">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

Expand Down
6 changes: 3 additions & 3 deletions app/src/main/java/com/fpvout/digiview/OverlayView.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ public class OverlayView extends ConstraintLayout {
public OverlayView(Context context, AttributeSet attrs) {
super(context, attrs);

inflate(getContext(),R.layout.backdrop_view,this);
inflate(getContext(),R.layout.overlay_view,this);

textView = findViewById(R.id.backdrop_text);
textView = findViewById(R.id.overlay_text);

imageView = findViewById(R.id.backdrop_image);
imageView = findViewById(R.id.overlay_image);
}

public void hide(){
Expand Down
Binary file removed app/src/main/res/drawable-hdpi/ic_splash.png
Binary file not shown.
Binary file removed app/src/main/res/drawable-mdpi/ic_splash.png
Binary file not shown.
Binary file removed app/src/main/res/drawable-xhdpi/ic_splash.png
Binary file not shown.
Binary file removed app/src/main/res/drawable-xxhdpi/ic_splash.png
Binary file not shown.
Binary file modified app/src/main/res/drawable-xxxhdpi/ic_splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 4 additions & 6 deletions app/src/main/res/drawable/splash.xml
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android"
android:opacity="opaque"
android:gravity="fill">
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">

<item android:drawable="@color/black"/>

<item>
<bitmap android:src="@drawable/ic_splash" />
</item>
<item
android:gravity="center"
android:drawable="@drawable/ic_splash" />

</layer-list>
Original file line number Diff line number Diff line change
Expand Up @@ -7,51 +7,39 @@
android:layout_width="match_parent"
android:layout_height="match_parent">


<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="0dp"
android:layout_height="match_parent"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="@id/backdrop_right_guideline"
app:layout_constraintStart_toStartOf="@id/backdrop_left_guideline"
app:layout_constraintTop_toTopOf="parent">
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
android:layout_width="wrap_content"
android:layout_height="wrap_content">

<ImageView
android:id="@+id/backdrop_image"
android:id="@+id/overlay_image"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.4"
app:layout_constraintBottom_toTopOf="@id/overlay_text"
app:srcCompat="@drawable/ic_goggles_white"
tools:ignore="ContentDescription" />

<TextView
android:id="@+id/backdrop_text"
android:id="@+id/overlay_text"
style="@style/text_status"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:layout_marginTop="25dp"
android:layout_marginBottom="25dp"
android:text="@string/app_name"
app:layout_constraintTop_toBottomOf="@+id/overlay_image"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintTop_toBottomOf="@+id/backdrop_image"
app:layout_constraintVertical_bias="0.0" />
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"/>

</androidx.constraintlayout.widget.ConstraintLayout>

<androidx.constraintlayout.widget.Guideline
android:id="@+id/backdrop_left_guideline"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_percent="0.15" />

<androidx.constraintlayout.widget.Guideline
android:id="@+id/backdrop_right_guideline"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
app:layout_constraintGuide_percent="0.85" />

</androidx.constraintlayout.widget.ConstraintLayout>
4 changes: 4 additions & 0 deletions app/src/main/res/values/themes.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,8 @@
<item name="android:statusBarColor" tools:targetApi="l">?attr/colorSecondary</item>
<!-- Customize your theme here. -->
</style>
<style name="Theme.DigiviewStartup" parent="Theme.Digiview">
<item name="android:statusBarColor" tools:targetApi="l">@color/black</item>
<item name="android:windowBackground">@drawable/splash</item>
</style>
</resources>