summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Matt Pietal <mpietal@google.com> 2020-03-24 14:38:39 -0400
committer Matt Pietal <mpietal@google.com> 2020-03-24 14:48:43 -0400
commit9e3d40d2659823988845d5d6e148c074cc27aacf (patch)
tree10f6e55b0b02c2d07aadbfe14b580fd6f1e26703
parent887941cbc8384e5d1df077292a98f08f1b54d0d4 (diff)
Controls Ui - More string adjustments
More adjustments based on feedback Bug: 151322044 Test: manual Change-Id: I682f51ecafa8c8d800e89842f51f013a4d2bc883
-rw-r--r--packages/SystemUI/res/layout/controls_no_favorites.xml1
-rw-r--r--packages/SystemUI/res/values/strings.xml17
-rw-r--r--packages/SystemUI/src/com/android/systemui/controls/management/ControlsProviderSelectorActivity.kt4
-rw-r--r--packages/SystemUI/src/com/android/systemui/controls/ui/ControlsUiControllerImpl.kt5
4 files changed, 13 insertions, 14 deletions
diff --git a/packages/SystemUI/res/layout/controls_no_favorites.xml b/packages/SystemUI/res/layout/controls_no_favorites.xml
index 74fc167c4632..41282301ab1c 100644
--- a/packages/SystemUI/res/layout/controls_no_favorites.xml
+++ b/packages/SystemUI/res/layout/controls_no_favorites.xml
@@ -50,7 +50,6 @@
<TextView
style="@style/TextAppearance.ControlSetup.Subtitle"
android:id="@+id/controls_subtitle"
- android:visibility="gone"
android:layout_marginTop="12dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
diff --git a/packages/SystemUI/res/values/strings.xml b/packages/SystemUI/res/values/strings.xml
index f71c0b39c62a..38c931a9847f 100644
--- a/packages/SystemUI/res/values/strings.xml
+++ b/packages/SystemUI/res/values/strings.xml
@@ -2636,14 +2636,17 @@
<!-- Quick Controls strings -->
<!-- Quick Controls empty state, title [CHAR LIMIT=30] -->
- <string name="quick_controls_title">Quick Controls</string>
+ <string name="quick_controls_title">Quick controls</string>
<!-- Quick Controls empty state, subtitle [CHAR LIMIT=100] -->
<string name="quick_controls_subtitle">Add controls for your connected devices</string>
- <!-- Controls management providers screen title [CHAR LIMIT=30]-->
- <string name="controls_providers_title">Add Controls</string>
- <!-- Controls management providers screen subtitle [CHAR LIMIT=NONE] -->
- <string name="controls_providers_subtitle">Choose app to add controls</string>
+ <!-- Quick Controls setup, title [CHAR LIMIT=50] -->
+ <string name="quick_controls_setup_title">Set up quick controls</string>
+ <!-- Quick Controls setup, subtitle [CHAR LIMIT=100] -->
+ <string name="quick_controls_setup_subtitle">Hold the Power button to access your controls</string>
+
+ <!-- Controls management providers screen title [CHAR LIMIT=60]-->
+ <string name="controls_providers_title">Choose app to add controls</string>
<!-- Number of favorites for controls management screen [CHAR LIMIT=NONE]-->
<plurals name="controls_number_of_favorites">
<item quantity="one"><xliff:g id="number" example="1">%s</xliff:g> control added.</item>
@@ -2679,12 +2682,8 @@
<string name="controls_pin_verifying">Verifying\u2026</string>
<!-- Controls PIN entry dialog, text hint [CHAR LIMIT=30] -->
<string name="controls_pin_instructions">Enter PIN</string>
- <!-- Controls passphrase entry dialog, text hint [CHAR LIMIT=30] -->
- <string name="controls_passphrase_instructions">Enter passphrase</string>
<!-- Controls PIN entry dialog, text hint, retry [CHAR LIMIT=30] -->
<string name="controls_pin_instructions_retry">Try another PIN</string>
- <!-- Controls passphrase entry dialog, text hint, retry [CHAR LIMIT=50] -->
- <string name="controls_passphrase_instructions_retry">Try another passphrase</string>
<!-- Controls confirmation dialog, waiting to confirm [CHAR LIMIT=30] -->
<string name="controls_confirmation_confirming">Confirming\u2026</string>
<!-- Controls confirmation dialog, user prompt [CHAR LIMIT=NONE] -->
diff --git a/packages/SystemUI/src/com/android/systemui/controls/management/ControlsProviderSelectorActivity.kt b/packages/SystemUI/src/com/android/systemui/controls/management/ControlsProviderSelectorActivity.kt
index 098caf61a873..0c41f7e5df5a 100644
--- a/packages/SystemUI/src/com/android/systemui/controls/management/ControlsProviderSelectorActivity.kt
+++ b/packages/SystemUI/src/com/android/systemui/controls/management/ControlsProviderSelectorActivity.kt
@@ -84,8 +84,6 @@ class ControlsProviderSelectorActivity @Inject constructor(
requireViewById<TextView>(R.id.title).text =
resources.getText(R.string.controls_providers_title)
- requireViewById<TextView>(R.id.subtitle).text =
- resources.getText(R.string.controls_providers_subtitle)
requireViewById<Button>(R.id.done).setOnClickListener {
this@ControlsProviderSelectorActivity.finishAffinity()
@@ -117,4 +115,4 @@ class ControlsProviderSelectorActivity @Inject constructor(
currentUserTracker.stopTracking()
super.onDestroy()
}
-} \ No newline at end of file
+}
diff --git a/packages/SystemUI/src/com/android/systemui/controls/ui/ControlsUiControllerImpl.kt b/packages/SystemUI/src/com/android/systemui/controls/ui/ControlsUiControllerImpl.kt
index 34dcca2859e7..b0db4370f38d 100644
--- a/packages/SystemUI/src/com/android/systemui/controls/ui/ControlsUiControllerImpl.kt
+++ b/packages/SystemUI/src/com/android/systemui/controls/ui/ControlsUiControllerImpl.kt
@@ -172,7 +172,7 @@ class ControlsUiControllerImpl @Inject constructor (
val inflater = LayoutInflater.from(context)
inflater.inflate(R.layout.controls_no_favorites, parent, true)
val subtitle = parent.requireViewById<TextView>(R.id.controls_subtitle)
- subtitle.setVisibility(View.VISIBLE)
+ subtitle.setText(context.resources.getString(R.string.controls_seeding_in_progress))
}
private fun showInitialSetupView(items: List<SelectionItem>) {
@@ -184,6 +184,9 @@ class ControlsUiControllerImpl @Inject constructor (
val viewGroup = parent.requireViewById(R.id.controls_no_favorites_group) as ViewGroup
viewGroup.setOnClickListener(launchSelectorActivityListener(context))
+ val subtitle = parent.requireViewById<TextView>(R.id.controls_subtitle)
+ subtitle.setText(context.resources.getString(R.string.quick_controls_subtitle))
+
val iconRowGroup = parent.requireViewById(R.id.controls_icon_row) as ViewGroup
items.forEach {
val imageView = inflater.inflate(R.layout.controls_icon, viewGroup, false) as ImageView