summaryrefslogtreecommitdiffstats
path: root/packages/SystemUI
diff options
context:
space:
mode:
authorRoman Birg <roman@cyngn.com>2016-05-17 13:12:39 -0700
committerGerrit Code Review <gerrit@cyanogenmod.org>2016-05-19 15:23:04 -0700
commitb4d593ba287562757345b43d6c49ef449ef78f5f (patch)
treeb7729eba46c74ef4ac0351d25b557676e074faa5 /packages/SystemUI
parent0b4226b8e49b5b813cc13c80b2ee266ea1614407 (diff)
downloadframeworks_base-b4d593ba287562757345b43d6c49ef449ef78f5f.zip
frameworks_base-b4d593ba287562757345b43d6c49ef449ef78f5f.tar.gz
frameworks_base-b4d593ba287562757345b43d6c49ef449ef78f5f.tar.bz2
SystemUI: update qs tile hint and header view on locale change
Ticket: CYNGNOS-2814 Change-Id: I305ac5eca862ffa5c525ec6b39bfeddf03719227 Signed-off-by: Roman Birg <roman@cyngn.com>
Diffstat (limited to 'packages/SystemUI')
-rw-r--r--packages/SystemUI/res/layout/qs_tile_top.xml2
-rw-r--r--packages/SystemUI/src/com/android/systemui/qs/QSDragPanel.java3
-rw-r--r--packages/SystemUI/src/com/android/systemui/qs/QSPanelTopView.java9
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarHeaderView.java4
4 files changed, 16 insertions, 2 deletions
diff --git a/packages/SystemUI/res/layout/qs_tile_top.xml b/packages/SystemUI/res/layout/qs_tile_top.xml
index a302c73..1602e21 100644
--- a/packages/SystemUI/res/layout/qs_tile_top.xml
+++ b/packages/SystemUI/res/layout/qs_tile_top.xml
@@ -54,12 +54,12 @@
android:orientation="horizontal">
<TextView
+ android:id="@+id/edit_text_instruction"
android:layout_width="0dp"
android:layout_height="match_parent"
android:gravity="center_vertical"
android:layout_weight="1"
android:textColor="@color/qs_edit_header_instruction_text_color"
- android:text="@string/qs_tile_edit_header_instruction"
android:contentDescription="@null"/>
<ImageView
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSDragPanel.java b/packages/SystemUI/src/com/android/systemui/qs/QSDragPanel.java
index 5ecc2a6..74b1bc7 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSDragPanel.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSDragPanel.java
@@ -1869,10 +1869,11 @@ public class QSDragPanel extends QSPanel implements View.OnDragListener, View.On
for (TileRecord r : mRecords) {
r.tile.clearState();
}
+ updateDetailText();
+ mQsPanelTop.updateResources();
if (mListening) {
refreshAllTiles();
}
- updateDetailText();
}
}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSPanelTopView.java b/packages/SystemUI/src/com/android/systemui/qs/QSPanelTopView.java
index 5f57be1..b00483c 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSPanelTopView.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSPanelTopView.java
@@ -53,6 +53,7 @@ public class QSPanelTopView extends FrameLayout {
protected View mBrightnessView;
protected TextView mToastView;
protected View mAddTarget;
+ protected TextView mEditInstructionText;
private boolean mEditing = false;
private boolean mDisplayingInstructions = false;
@@ -112,6 +113,14 @@ public class QSPanelTopView extends FrameLayout {
mBrightnessView = findViewById(R.id.brightness_container);
mToastView = (TextView) findViewById(R.id.qs_toast);
mAddTarget = findViewById(R.id.add_target);
+ mEditInstructionText = (TextView) findViewById(R.id.edit_text_instruction);
+ updateResources();
+ }
+
+ public void updateResources() {
+ if (mEditInstructionText != null) {
+ mEditInstructionText.setText(R.string.qs_tile_edit_header_instruction);
+ }
}
@Override
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarHeaderView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarHeaderView.java
index c3feaf1..f9b1f38 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarHeaderView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarHeaderView.java
@@ -281,6 +281,10 @@ public class StatusBarHeaderView extends RelativeLayout implements View.OnClickL
mClockExpandedSize = getResources().getDimensionPixelSize(R.dimen.qs_time_expanded_size);
mClockCollapsedScaleFactor = (float) mClockCollapsedSize / (float) mClockExpandedSize;
+ if (mEditTileDoneText != null) {
+ mEditTileDoneText.setText(R.string.quick_settings_done);
+ }
+
updateClockScale();
updateClockCollapsedMargin();
}