UI bugs fix

This commit is contained in:
Matéo Duparc 2021-03-16 16:32:46 +01:00
parent 4c66251b70
commit 6f6b670ff6
Signed by untrusted user: hardcoresushi
GPG Key ID: 007F84120107191E
3 changed files with 40 additions and 52 deletions

View File

@ -15,8 +15,8 @@ android {
applicationId "sushi.hardcore.droidfs" applicationId "sushi.hardcore.droidfs"
minSdkVersion 21 minSdkVersion 21
targetSdkVersion 29 targetSdkVersion 29
versionCode 10 versionCode 11
versionName "1.4.2" versionName "1.4.3"
ndk { ndk {
abiFilters 'x86_64', 'armeabi-v7a', 'arm64-v8a' abiFilters 'x86_64', 'armeabi-v7a', 'arm64-v8a'

View File

@ -22,10 +22,6 @@ class MainActivity : BaseActivity() {
super.onCreate(savedInstanceState) super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main) setContentView(R.layout.activity_main)
setSupportActionBar(toolbar) setSupportActionBar(toolbar)
val metrics = DisplayMetrics()
windowManager.defaultDisplay.getMetrics(metrics)
image_logo.layoutParams.height = (metrics.heightPixels/2.2).toInt()
Glide.with(this).load(R.drawable.logo).into(image_logo)
if (!isRecreating){ if (!isRecreating){
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
if (ContextCompat.checkSelfPermission(this, Manifest.permission.READ_EXTERNAL_STORAGE) + if (ContextCompat.checkSelfPermission(this, Manifest.permission.READ_EXTERNAL_STORAGE) +

View File

@ -8,25 +8,21 @@
<include layout="@layout/toolbar"/> <include layout="@layout/toolbar"/>
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<sushi.hardcore.droidfs.widgets.ColoredImageView <sushi.hardcore.droidfs.widgets.ColoredImageView
android:id="@+id/image_logo" android:id="@+id/image_logo"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="0dp"
android:layout_margin="20dp"/> android:layout_margin="30dp"
android:src="@drawable/logo"
android:layout_weight="1"/>
<LinearLayout <LinearLayout
android:id="@+id/aaa"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="0dp"
android:orientation="vertical"> android:orientation="vertical"
android:layout_weight="1">
<androidx.appcompat.widget.AppCompatButton <androidx.appcompat.widget.AppCompatButton
android:layout_width="match_parent" android:layout_width="match_parent"
@ -57,8 +53,4 @@
</LinearLayout> </LinearLayout>
</LinearLayout>
</ScrollView>
</LinearLayout> </LinearLayout>