Remove generic unknown value label and replace it with more specific variants.

This commit is contained in:
darken
2022-02-03 09:34:55 +01:00
parent 6d6647e511
commit 59c0e818e1
6 changed files with 9 additions and 8 deletions
@@ -85,7 +85,7 @@ class DualApplePodsCardVH(parent: ViewGroup) :
podCaseLidLabel.text = when (caseLidState) {
LidState.OPEN -> context.getString(R.string.pods_case_status_open_label)
LidState.CLOSED -> context.getString(R.string.pods_case_status_closed_label)
else -> context.getString(R.string.general_value_unknown_label)
else -> context.getString(R.string.pods_case_unknown_state)
}
val hideInfo = !listOf(LidState.OPEN, LidState.CLOSED).contains(caseLidState)
@@ -178,7 +178,7 @@ interface DualApplePods : ApplePods, HasDualPods, HasDualEarDetection, HasCase {
CALL(0x06, R.string.pods_connection_state_call_label),
RINGING(0x07, R.string.pods_connection_state_ringing_label),
HANGING_UP(0x09, R.string.pods_connection_state_hanging_up_label),
UNKNOWN(null, R.string.general_value_unknown_label);
UNKNOWN(null, R.string.pods_connection_state_unknown_label);
constructor(raw: Int, @StringRes labelRes: Int) : this(raw.toUByte(), labelRes)
}
@@ -148,7 +148,7 @@
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="2dp"
android:text="@string/general_value_unknown_label"
android:text="@string/general_value_not_available_label"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@id/pod_left_battery_icon"
app:layout_constraintTop_toBottomOf="@id/pod_left_label" />
@@ -260,7 +260,7 @@
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="2dp"
android:text="@string/general_value_unknown_label"
android:text="@string/general_value_not_available_label"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@id/pod_case_battery_icon"
app:layout_constraintTop_toBottomOf="@id/pod_case_label" />
@@ -353,7 +353,7 @@
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="2dp"
android:text="@string/general_value_unknown_label"
android:text="@string/general_value_not_available_label"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@id/pod_right_battery_icon"
app:layout_constraintTop_toBottomOf="@id/pod_right_label" />
@@ -118,7 +118,7 @@
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="2dp"
android:text="@string/general_value_unknown_label"
android:text="@string/general_value_not_available_label"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@id/battery_icon"
app:layout_constraintTop_toTopOf="parent" />
@@ -119,7 +119,7 @@
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="2dp"
android:text="@string/general_value_unknown_label"
android:text="@string/general_value_not_available_label"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@id/battery_icon"
app:layout_constraintTop_toTopOf="parent" />
+2 -1
View File
@@ -9,7 +9,6 @@
<string name="general_share_action">Share</string>
<string name="general_done_action">Done</string>
<string name="general_copy_action">Copy</string>
<string name="general_value_unknown_label">Unknown</string>
<string name="general_thank_you_label">Thank you</string>
<string name="general_value_not_available_label">N/A</string>
<string name="general_grant_permission_action">Grant permission</string>
@@ -47,6 +46,7 @@
<string name="pods_connection_state_call_label">In call mode</string>
<string name="pods_connection_state_ringing_label">Ringing</string>
<string name="pods_connection_state_hanging_up_label">Hanging up</string>
<string name="pods_connection_state_unknown_label">Unknown connection state</string>
<string name="pods_unknown_raw_data_label">Raw data</string>
<string name="pods_unknown_label">Unknown device</string>
<string name="pods_unknown_contact_dev">This is an unknown device, but it is using similar message format. Let\'s add support for it, contact me :)</string>
@@ -56,6 +56,7 @@
<string name="pods_microphone_label">Microphone</string>
<string name="pods_yours">Yours</string>
<string name="headset_being_worn_label">Being worn</string>
<string name="pods_case_unknown_state">Unknown state</string>
<string name="overview_nomaindevice_label">No primary device</string>
<string name="overview_nomaindevice_description">All detected devices are unlikely to be yours. Power on and connect your device or adjust the settings.</string>