chore: bump compileSdk/targetSdk to 36, fix layout fitsSystemWindows
This commit is contained in:
parent
b2662247bb
commit
799c4dfae8
3 changed files with 174 additions and 157 deletions
|
|
@ -11,7 +11,7 @@ android {
|
|||
// compileSdk/targetSdk stays on 34 (Android 14) by deliberate choice. The target audience
|
||||
// consists of physically disabled users who are very reluctant to update their phones. Staying
|
||||
// on API 34 maximises device compatibility. Re-evaluate when the user base has migrated.
|
||||
compileSdk 34
|
||||
compileSdk 36
|
||||
|
||||
if (hasSigningConfig) {
|
||||
def props = new Properties()
|
||||
|
|
@ -30,7 +30,7 @@ android {
|
|||
defaultConfig {
|
||||
applicationId "nl.eddydevink.sylda"
|
||||
minSdk 26
|
||||
targetSdk 34
|
||||
targetSdk 36
|
||||
versionCode 1
|
||||
versionName "1.0"
|
||||
buildConfigField "String", "BUILD_NUMBER", "\"${new java.text.SimpleDateFormat("yyyyMMddHHmmss").format(new Date())}\""
|
||||
|
|
|
|||
|
|
@ -2,69 +2,77 @@
|
|||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="16dp">
|
||||
android:fitsSystemWindows="true">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="16dp">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/settingsContainer"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="end|top"
|
||||
android:layout_marginTop="8dp"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center_vertical"
|
||||
android:background="?android:attr/selectableItemBackground"
|
||||
android:clickable="true"
|
||||
android:focusable="true">
|
||||
|
||||
<TextView
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/settings_label"
|
||||
android:textSize="14sp"
|
||||
android:layout_marginEnd="4dp" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/settingsButton"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:src="@drawable/ic_settings"
|
||||
android:background="?android:attr/selectableItemBackgroundBorderless"
|
||||
android:contentDescription="@string/cd_settings" />
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/settings_label"
|
||||
android:textSize="14sp"
|
||||
android:layout_marginEnd="4dp" />
|
||||
android:layout_gravity="center"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center">
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/settingsButton"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:src="@drawable/ic_settings"
|
||||
android:background="?android:attr/selectableItemBackgroundBorderless"
|
||||
android:contentDescription="@string/cd_settings" />
|
||||
</LinearLayout>
|
||||
<Button
|
||||
android:id="@+id/relay1Button"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="200dp"
|
||||
android:text="1"
|
||||
android:textSize="24sp"
|
||||
android:textAllCaps="false"
|
||||
android:enabled="false" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center">
|
||||
<Button
|
||||
android:id="@+id/relay2Button"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="200dp"
|
||||
android:layout_marginStart="16dp"
|
||||
android:text="2"
|
||||
android:textSize="24sp"
|
||||
android:textAllCaps="false"
|
||||
android:enabled="false" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/relay1Button"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="200dp"
|
||||
android:text="1"
|
||||
android:textSize="24sp"
|
||||
android:textAllCaps="false"
|
||||
android:enabled="false" />
|
||||
</LinearLayout>
|
||||
|
||||
<Button
|
||||
android:id="@+id/relay2Button"
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="200dp"
|
||||
android:layout_marginStart="16dp"
|
||||
android:text="2"
|
||||
android:textSize="24sp"
|
||||
android:textAllCaps="false"
|
||||
android:enabled="false" />
|
||||
<TextView
|
||||
android:id="@+id/statusText"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom|start"
|
||||
android:text="@string/status_default"
|
||||
android:textSize="14sp" />
|
||||
|
||||
</LinearLayout>
|
||||
</FrameLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/statusText"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="bottom|start"
|
||||
android:text="@string/status_default"
|
||||
android:textSize="14sp" />
|
||||
|
||||
</FrameLayout>
|
||||
</FrameLayout>
|
||||
|
|
|
|||
|
|
@ -3,138 +3,147 @@
|
|||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:padding="24dp">
|
||||
|
||||
<RadioGroup
|
||||
android:id="@+id/flashMethodGroup"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginBottom="8dp"
|
||||
android:checkedButton="@id/methodBluetooth">
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/methodBluetooth"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@string/method_bluetooth" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/methodUsb"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@string/method_usb" />
|
||||
</RadioGroup>
|
||||
|
||||
<Button
|
||||
android:id="@+id/updateModuleButton"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/button_update_module" />
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="?android:attr/listDivider"
|
||||
android:layout_marginTop="24dp"
|
||||
android:layout_marginBottom="16dp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/section_labels"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold"
|
||||
android:layout_marginBottom="8dp" />
|
||||
android:fitsSystemWindows="true">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginBottom="16dp">
|
||||
|
||||
<EditText
|
||||
android:id="@+id/labelRelay1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:hint="@string/hint_label_relay1"
|
||||
android:maxLines="1"
|
||||
android:inputType="text"
|
||||
android:imeOptions="actionDone"
|
||||
android:gravity="center" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/labelRelay2"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:hint="@string/hint_label_relay2"
|
||||
android:maxLines="1"
|
||||
android:inputType="text"
|
||||
android:imeOptions="actionDone"
|
||||
android:gravity="center" />
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="?android:attr/listDivider"
|
||||
android:layout_marginBottom="16dp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/section_theme"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold"
|
||||
android:layout_marginBottom="8dp" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:weightSum="3">
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:padding="24dp"
|
||||
android:layout_marginTop="8dp">
|
||||
|
||||
<RadioGroup
|
||||
android:id="@+id/themeGroup"
|
||||
android:id="@+id/flashMethodGroup"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginBottom="8dp"
|
||||
android:checkedButton="@id/methodBluetooth">
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/themeSystem"
|
||||
android:id="@+id/methodBluetooth"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@string/theme_system" />
|
||||
android:text="@string/method_bluetooth" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/themeLight"
|
||||
android:id="@+id/methodUsb"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@string/theme_light" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/themeDark"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@string/theme_dark" />
|
||||
android:text="@string/method_usb" />
|
||||
</RadioGroup>
|
||||
|
||||
<Button
|
||||
android:id="@+id/updateModuleButton"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/button_update_module" />
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="?android:attr/listDivider"
|
||||
android:layout_marginTop="24dp"
|
||||
android:layout_marginBottom="16dp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/section_labels"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold"
|
||||
android:layout_marginBottom="8dp" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginBottom="16dp">
|
||||
|
||||
<EditText
|
||||
android:id="@+id/labelRelay1"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:hint="@string/hint_label_relay1"
|
||||
android:maxLines="1"
|
||||
android:inputType="text"
|
||||
android:imeOptions="actionDone"
|
||||
android:gravity="center" />
|
||||
|
||||
<EditText
|
||||
android:id="@+id/labelRelay2"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:hint="@string/hint_label_relay2"
|
||||
android:maxLines="1"
|
||||
android:inputType="text"
|
||||
android:imeOptions="actionDone"
|
||||
android:gravity="center" />
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="?android:attr/listDivider"
|
||||
android:layout_marginBottom="16dp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/section_theme"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold"
|
||||
android:layout_marginBottom="8dp" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:weightSum="3">
|
||||
|
||||
<RadioGroup
|
||||
android:id="@+id/themeGroup"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/themeSystem"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@string/theme_system" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/themeLight"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@string/theme_light" />
|
||||
|
||||
<RadioButton
|
||||
android:id="@+id/themeDark"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:gravity="center"
|
||||
android:text="@string/theme_dark" />
|
||||
</RadioGroup>
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1" />
|
||||
|
||||
</LinearLayout>
|
||||
|
|
|
|||
Loading…
Reference in a new issue