From 6a0f6091f12a355a1cb053395b077bdcc14188bb Mon Sep 17 00:00:00 2001 From: Andries Smit Date: Tue, 19 Apr 2022 12:31:20 +0200 Subject: [PATCH] chore: fix lint warnings --- .../res/layout/activity_profilehelper.xml | 6 +-- .../res/layout/automation_action_item.xml | 7 ++- .../res/layout/automation_dialog_action.xml | 4 +- .../automation_dialog_choose_action.xml | 6 +-- .../automation_dialog_choose_trigger.xml | 4 +- .../res/layout/automation_dialog_event.xml | 13 +++-- core/src/main/res/layout/datetime.xml | 13 ++--- .../res/layout/dialog_alert_custom_title.xml | 3 +- .../layout/maintenance_import_list_item.xml | 18 +++---- core/src/main/res/layout/passwordprompt.xml | 5 +- core/src/main/res/layout/toast.xml | 7 +-- core/src/main/res/values/strings.xml | 2 + .../main/res/layout/danar_history_item.xml | 12 ++--- .../layout/danar_user_options_activity.xml | 23 ++++----- .../layout/danars_pairing_progress_dialog.xml | 2 +- .../res/layout/diaconn_g8_history_item.xml | 47 ++++++++++--------- .../diaconn_g8_user_options_activity.xml | 24 ++-------- .../src/main/res/layout/bluetooth_device.xml | 13 ++--- .../res/layout/local_insight_status_item.xml | 9 +++- .../main/res/layout/medtronic_fragment.xml | 16 +------ .../res/layout/medtronic_history_activity.xml | 8 ++-- .../res/layout/medtronic_history_item.xml | 18 +++---- medtronic/src/main/res/values/strings.xml | 2 + .../omnipod_dash_pod_history_activity.xml | 2 +- .../omnipod_eros_pod_history_activity.xml | 2 +- .../layout/riley_link_ble_config_activity.xml | 3 ++ .../riley_link_ble_config_scan_item.xml | 3 +- .../src/main/res/layout/rileylink_status.xml | 6 +-- .../res/layout/rileylink_status_device.xml | 5 +- .../layout/rileylink_status_device_item.xml | 18 +++---- .../res/layout/rileylink_status_history.xml | 8 ++-- .../layout/rileylink_status_history_item.xml | 21 +++++---- 32 files changed, 162 insertions(+), 168 deletions(-) diff --git a/app/src/main/res/layout/activity_profilehelper.xml b/app/src/main/res/layout/activity_profilehelper.xml index 615958b310..f1621b78df 100644 --- a/app/src/main/res/layout/activity_profilehelper.xml +++ b/app/src/main/res/layout/activity_profilehelper.xml @@ -27,8 +27,7 @@ android:gravity="center" android:paddingStart="5dp" android:paddingEnd="5dp" - android:text="1" - tools:ignore="HardcodedText" /> + android:text="Profile 1" /> + android:text="Profile 2" /> diff --git a/automation/src/main/res/layout/automation_action_item.xml b/automation/src/main/res/layout/automation_action_item.xml index 24697cee75..187abda4a9 100644 --- a/automation/src/main/res/layout/automation_action_item.xml +++ b/automation/src/main/res/layout/automation_action_item.xml @@ -2,6 +2,7 @@ + android:orientation="horizontal" + tools:ignore="UseCompoundDrawables"> - \ No newline at end of file + diff --git a/automation/src/main/res/layout/automation_dialog_action.xml b/automation/src/main/res/layout/automation_dialog_action.xml index 0ec8a68c46..ba6a516e70 100644 --- a/automation/src/main/res/layout/automation_dialog_action.xml +++ b/automation/src/main/res/layout/automation_dialog_action.xml @@ -6,7 +6,7 @@ android:layout_width="match_parent" android:layout_height="match_parent" android:focusableInTouchMode="true" - tools:context=".plugins.general.automation.dialogs.EditActionDialog"> + tools:context="info.nightscout.androidaps.plugins.general.automation.dialogs.EditActionDialog"> - \ No newline at end of file + diff --git a/automation/src/main/res/layout/automation_dialog_choose_action.xml b/automation/src/main/res/layout/automation_dialog_choose_action.xml index f3aaebd19b..ac3997cf97 100644 --- a/automation/src/main/res/layout/automation_dialog_choose_action.xml +++ b/automation/src/main/res/layout/automation_dialog_choose_action.xml @@ -2,12 +2,10 @@ + tools:context="info.nightscout.androidaps.plugins.general.automation.dialogs.EditEventDialog"> - \ No newline at end of file + diff --git a/automation/src/main/res/layout/automation_dialog_choose_trigger.xml b/automation/src/main/res/layout/automation_dialog_choose_trigger.xml index f88d4a1078..c4c139c607 100644 --- a/automation/src/main/res/layout/automation_dialog_choose_trigger.xml +++ b/automation/src/main/res/layout/automation_dialog_choose_trigger.xml @@ -6,7 +6,7 @@ android:layout_width="match_parent" android:layout_height="match_parent" android:focusableInTouchMode="true" - tools:context=".plugins.general.automation.dialogs.EditEventDialog"> + tools:context="info.nightscout.androidaps.plugins.general.automation.dialogs.EditEventDialog"> - \ No newline at end of file + diff --git a/automation/src/main/res/layout/automation_dialog_event.xml b/automation/src/main/res/layout/automation_dialog_event.xml index 9109c1a520..a94169dd49 100644 --- a/automation/src/main/res/layout/automation_dialog_event.xml +++ b/automation/src/main/res/layout/automation_dialog_event.xml @@ -26,7 +26,7 @@ app:srcCompat="@drawable/ic_action_orange_48dp" /> @@ -93,6 +94,7 @@ android:layout_width="24dp" android:layout_height="24dp" android:layout_centerVertical="true" + android:importantForAccessibility="no" app:srcCompat="@drawable/ic_trigger_green_48dp" /> + android:text="@string/edit_short" + tools:ignore="RelativeOverlap" /> @@ -156,6 +159,7 @@ android:layout_width="24dp" android:layout_height="24dp" android:layout_centerVertical="true" + android:importantForAccessibility="no" app:srcCompat="@drawable/ic_action_orange_48dp" /> + android:text="@string/add_short" + tools:ignore="RelativeOverlap" /> @@ -195,4 +200,4 @@ - \ No newline at end of file + diff --git a/core/src/main/res/layout/datetime.xml b/core/src/main/res/layout/datetime.xml index 07e7ba30fe..507595174d 100644 --- a/core/src/main/res/layout/datetime.xml +++ b/core/src/main/res/layout/datetime.xml @@ -1,9 +1,10 @@ + android:orientation="horizontal" + android:paddingTop="2dp"> + tools:text="2017/05/05" /> + tools:text="08:20pm" /> diff --git a/core/src/main/res/layout/dialog_alert_custom_title.xml b/core/src/main/res/layout/dialog_alert_custom_title.xml index 624b970c12..0c0641954d 100644 --- a/core/src/main/res/layout/dialog_alert_custom_title.xml +++ b/core/src/main/res/layout/dialog_alert_custom_title.xml @@ -18,6 +18,7 @@ android:id="@+id/alertdialog_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" + android:importantForAccessibility="no" app:tint="?dialogTitleIconTint" /> - \ No newline at end of file + diff --git a/core/src/main/res/layout/maintenance_import_list_item.xml b/core/src/main/res/layout/maintenance_import_list_item.xml index 39d68cfa89..d7e8cd1f18 100644 --- a/core/src/main/res/layout/maintenance_import_list_item.xml +++ b/core/src/main/res/layout/maintenance_import_list_item.xml @@ -27,7 +27,8 @@ android:layout_width="match_parent" android:layout_height="match_parent" android:baselineAligned="true" - android:orientation="horizontal"> + android:orientation="horizontal" + tools:ignore="UseCompoundDrawables"> @@ -46,6 +48,7 @@ android:layout_weight="1" android:ellipsize="none" android:maxLines="2" + android:paddingStart="0dp" android:paddingEnd="10dp" android:scrollHorizontally="false" android:text="File name here" @@ -53,7 +56,6 @@ android:textColor="?attr/importListFileNameColor" tools:ignore="HardcodedText" /> - - + android:orientation="horizontal" + tools:ignore="UseCompoundDrawables"> @@ -110,17 +112,14 @@ android:textColor="?attr/importListAdditionalInfoColor" tools:ignore="HardcodedText" /> - - - diff --git a/core/src/main/res/layout/passwordprompt.xml b/core/src/main/res/layout/passwordprompt.xml index ea4209edc3..05c300a702 100644 --- a/core/src/main/res/layout/passwordprompt.xml +++ b/core/src/main/res/layout/passwordprompt.xml @@ -21,9 +21,11 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:hint="@string/password_hint" + android:importantForAutofill="no" android:inputType="textPassword"> + - \ No newline at end of file + diff --git a/core/src/main/res/layout/toast.xml b/core/src/main/res/layout/toast.xml index 4572e3b408..8b79189760 100644 --- a/core/src/main/res/layout/toast.xml +++ b/core/src/main/res/layout/toast.xml @@ -26,8 +26,9 @@ android:layout_marginTop="4dp" android:layout_marginEnd="18dp" android:layout_marginBottom="4dp" - android:text="Toast goes here..." android:textColor="?attr/toastBaseTextColor" android:textSize="18sp" - tools:ignore="HardcodedText,RtlHardcoded" /> - \ No newline at end of file + tools:ignore="RtlHardcoded" + tools:text="Toast goes here..." /> + + diff --git a/core/src/main/res/values/strings.xml b/core/src/main/res/values/strings.xml index 74e30a005c..39ff22b27b 100644 --- a/core/src/main/res/values/strings.xml +++ b/core/src/main/res/values/strings.xml @@ -561,6 +561,8 @@ Remove Items Sort Items Remove Selected Items + file + user %1$d day diff --git a/dana/src/main/res/layout/danar_history_item.xml b/dana/src/main/res/layout/danar_history_item.xml index 23b37e9e00..ddae424524 100644 --- a/dana/src/main/res/layout/danar_history_item.xml +++ b/dana/src/main/res/layout/danar_history_item.xml @@ -14,7 +14,6 @@ app:cardUseCompatPadding="true" android:layout_gravity="center"> - - @@ -64,7 +62,7 @@ android:id="@+id/duration" android:layout_width="30dp" android:layout_height="wrap_content" - android:gravity="right" + android:gravity="end" android:paddingStart="5dp" android:text="30" tools:ignore="HardcodedText,RtlHardcoded,RtlSymmetry" /> @@ -73,7 +71,7 @@ android:id="@+id/daily_basal" android:layout_width="50dp" android:layout_height="wrap_content" - android:gravity="right" + android:gravity="end" android:paddingStart="5dp" tools:ignore="RtlHardcoded,RtlSymmetry" /> @@ -81,7 +79,7 @@ android:id="@+id/daily_bolus" android:layout_width="50dp" android:layout_height="wrap_content" - android:gravity="right" + android:gravity="end" android:paddingStart="5dp" tools:ignore="RtlHardcoded,RtlSymmetry" /> @@ -89,7 +87,7 @@ android:id="@+id/daily_total" android:layout_width="56dp" android:layout_height="wrap_content" - android:gravity="right" + android:gravity="end" android:paddingStart="10dp" android:visibility="gone" tools:ignore="RtlHardcoded,RtlSymmetry" /> diff --git a/dana/src/main/res/layout/danar_user_options_activity.xml b/dana/src/main/res/layout/danar_user_options_activity.xml index ee76cba6bf..6e4f850ab1 100644 --- a/dana/src/main/res/layout/danar_user_options_activity.xml +++ b/dana/src/main/res/layout/danar_user_options_activity.xml @@ -8,7 +8,6 @@ android:focusableInTouchMode="true" tools:context="info.nightscout.androidaps.dana.activities.DanaUserOptionsActivity"> - - + android:textOn="@string/timeformat24h" + app:showText="true" /> - + android:textOn="@string/option_on" + app:showText="true" /> - + android:textOn="@string/option_on" + app:showText="true" /> - + android:textOn="@string/mmol" + app:showText="true" /> + tools:text="STATUS" /> - - + app:contentPadding="2dp"> - + android:paddingEnd="0dp" + tools:text="27.06.2016 18:00" /> + android:paddingEnd="0dp" + tools:text="0.25" /> + android:paddingEnd="0dp" + tools:text="E" /> + android:paddingEnd="0dp" + tools:text="XXXXXXX" /> + android:paddingEnd="0dp" + tools:text="30" /> + android:paddingEnd="0dp" /> + android:paddingEnd="0dp" /> + android:paddingEnd="0dp" + android:visibility="gone" /> + android:paddingStart="5dp" + android:paddingEnd="0dp" /> diff --git a/diaconn/src/main/res/layout/diaconn_g8_user_options_activity.xml b/diaconn/src/main/res/layout/diaconn_g8_user_options_activity.xml index 61a43250a5..85a4ba9aa8 100644 --- a/diaconn/src/main/res/layout/diaconn_g8_user_options_activity.xml +++ b/diaconn/src/main/res/layout/diaconn_g8_user_options_activity.xml @@ -8,7 +8,6 @@ android:focusableInTouchMode="true" tools:context="info.nightscout.androidaps.diaconn.activities.DiaconnG8UserOptionsActivity"> - - - @@ -191,17 +185,11 @@ - - - @@ -273,16 +261,11 @@ - - @@ -306,7 +289,6 @@ android:layout_marginBottom="5dp" android:background="?android:attr/dividerHorizontal" /> - \ No newline at end of file + android:gravity="center_vertical" + android:paddingStart="16dp" + android:paddingEnd="0dp" + android:textColor="#FFFFFF" + android:textSize="20sp" + tools:text="Test" /> diff --git a/insight/src/main/res/layout/local_insight_status_item.xml b/insight/src/main/res/layout/local_insight_status_item.xml index 38216e9b33..987d71b50e 100644 --- a/insight/src/main/res/layout/local_insight_status_item.xml +++ b/insight/src/main/res/layout/local_insight_status_item.xml @@ -1,5 +1,6 @@ @@ -10,6 +11,7 @@ android:layout_height="wrap_content" android:layout_weight="1" android:gravity="end" + android:paddingStart="0dp" android:paddingEnd="5dp" android:textSize="14sp" /> @@ -21,7 +23,8 @@ android:paddingStart="2dp" android:paddingEnd="2dp" android:text=":" - android:textSize="14sp" /> + android:textSize="14sp" + tools:ignore="HardcodedText" /> - \ No newline at end of file + + diff --git a/medtronic/src/main/res/layout/medtronic_fragment.xml b/medtronic/src/main/res/layout/medtronic_fragment.xml index ea92f2a590..db76e71150 100644 --- a/medtronic/src/main/res/layout/medtronic_fragment.xml +++ b/medtronic/src/main/res/layout/medtronic_fragment.xml @@ -4,14 +4,12 @@ android:layout_height="match_parent" tools:context="info.nightscout.androidaps.plugins.pump.medtronic.MedtronicFragment"> - - - - - - - - - - - - - - + android:text="@string/riley_statistics" /> diff --git a/medtronic/src/main/res/layout/medtronic_history_activity.xml b/medtronic/src/main/res/layout/medtronic_history_activity.xml index b9e95908df..91e8ddbc45 100644 --- a/medtronic/src/main/res/layout/medtronic_history_activity.xml +++ b/medtronic/src/main/res/layout/medtronic_history_activity.xml @@ -7,7 +7,6 @@ android:paddingTop="@dimen/activity_vertical_margin" tools:context="info.nightscout.androidaps.plugins.pump.medtronic.dialog.MedtronicHistoryActivity"> - - - + android:textSize="12sp" + tools:text="Date" /> + android:textSize="12sp" + tools:text="Source" /> + android:textSize="12sp" + tools:text="Description" /> - \ No newline at end of file + diff --git a/medtronic/src/main/res/values/strings.xml b/medtronic/src/main/res/values/strings.xml index 5ec63bcdfd..0e247f48b1 100644 --- a/medtronic/src/main/res/values/strings.xml +++ b/medtronic/src/main/res/values/strings.xml @@ -123,5 +123,7 @@ %1$.1f U/h (%2$d min remaining) ^\\d{6} Invalid pump history data detected. Open new issue and provide logs. + RL Stats + Type: \ No newline at end of file diff --git a/omnipod-dash/src/main/res/layout/omnipod_dash_pod_history_activity.xml b/omnipod-dash/src/main/res/layout/omnipod_dash_pod_history_activity.xml index be8a49d07a..fba452e2a2 100644 --- a/omnipod-dash/src/main/res/layout/omnipod_dash_pod_history_activity.xml +++ b/omnipod-dash/src/main/res/layout/omnipod_dash_pod_history_activity.xml @@ -29,7 +29,7 @@ + - \ No newline at end of file + diff --git a/rileylink/src/main/res/layout/rileylink_status.xml b/rileylink/src/main/res/layout/rileylink_status.xml index d73f137bcb..42882d46de 100644 --- a/rileylink/src/main/res/layout/rileylink_status.xml +++ b/rileylink/src/main/res/layout/rileylink_status.xml @@ -5,7 +5,6 @@ android:layout_width="match_parent" android:layout_height="match_parent" android:fitsSystemWindows="true" - tools:context="info.nightscout.androidaps.plugins.pump.common.hw.rileylink.dialog.RileyLinkStatusActivity"> - + - - diff --git a/rileylink/src/main/res/layout/rileylink_status_device.xml b/rileylink/src/main/res/layout/rileylink_status_device.xml index f56c4b0d6d..e8d1a63552 100644 --- a/rileylink/src/main/res/layout/rileylink_status_device.xml +++ b/rileylink/src/main/res/layout/rileylink_status_device.xml @@ -2,7 +2,7 @@ xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" - tools:context=".plugins.pump.medtronic.dialog.RileyLinkStatusDevice"> + tools:context="info.nightscout.androidaps.plugins.pump.common.hw.rileylink.dialog.RileyLinkStatusDevice"> + - \ No newline at end of file + diff --git a/rileylink/src/main/res/layout/rileylink_status_device_item.xml b/rileylink/src/main/res/layout/rileylink_status_device_item.xml index e8a81fbc6f..f37596f31f 100644 --- a/rileylink/src/main/res/layout/rileylink_status_device_item.xml +++ b/rileylink/src/main/res/layout/rileylink_status_device_item.xml @@ -1,25 +1,27 @@ + android:orientation="horizontal" + android:paddingStart="15dp" + android:paddingEnd="0dp"> + android:textSize="12sp" + tools:text="Command" /> + android:textSize="12sp" + tools:text="Description" /> - \ No newline at end of file + diff --git a/rileylink/src/main/res/layout/rileylink_status_history.xml b/rileylink/src/main/res/layout/rileylink_status_history.xml index 3a44c3a8e8..21a37379cb 100644 --- a/rileylink/src/main/res/layout/rileylink_status_history.xml +++ b/rileylink/src/main/res/layout/rileylink_status_history.xml @@ -12,17 +12,15 @@ + android:layout_height="fill_parent"/> - \ No newline at end of file + diff --git a/rileylink/src/main/res/layout/rileylink_status_history_item.xml b/rileylink/src/main/res/layout/rileylink_status_history_item.xml index 1a9a7a61c2..4e522c8899 100644 --- a/rileylink/src/main/res/layout/rileylink_status_history_item.xml +++ b/rileylink/src/main/res/layout/rileylink_status_history_item.xml @@ -1,33 +1,34 @@ - + android:orientation="horizontal" + android:paddingStart="20dp" + android:paddingEnd="0dp"> + android:textSize="12sp" + tools:text="Date" /> + android:textSize="12sp" + tools:text="Source" /> + android:textSize="12sp" + tools:text="Description" /> - \ No newline at end of file +