diff options
| author | Alan Viverette <alanv@google.com> | 2014-03-06 18:36:43 -0800 |
|---|---|---|
| committer | Alan Viverette <alanv@google.com> | 2014-03-06 18:36:43 -0800 |
| commit | 858a0405ec86328f2b853367be889ad9f64d40a4 (patch) | |
| tree | ce54c7deada8075b84346e674699f7f1350dd6f4 | |
| parent | 2228195452f96b312355e0e58d8c29d231ca3067 (diff) | |
| download | frameworks_base-858a0405ec86328f2b853367be889ad9f64d40a4.zip frameworks_base-858a0405ec86328f2b853367be889ad9f64d40a4.tar.gz frameworks_base-858a0405ec86328f2b853367be889ad9f64d40a4.tar.bz2 | |
Add icons for display adjustment quick settings
BUG: 13028934
Change-Id: I437abc48ad34364995b37c504019f7a4871c8031
23 files changed, 132 insertions, 6 deletions
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_qs_color_space_alpha.png b/packages/SystemUI/res/drawable-hdpi/ic_qs_color_space_alpha.png Binary files differnew file mode 100644 index 0000000..fe6dc52 --- /dev/null +++ b/packages/SystemUI/res/drawable-hdpi/ic_qs_color_space_alpha.png diff --git a/packages/SystemUI/res/drawable-hdpi/ic_qs_contrast_alpha.png b/packages/SystemUI/res/drawable-hdpi/ic_qs_contrast_alpha.png Binary files differnew file mode 100644 index 0000000..0f9dfc7 --- /dev/null +++ b/packages/SystemUI/res/drawable-hdpi/ic_qs_contrast_alpha.png diff --git a/packages/SystemUI/res/drawable-hdpi/ic_qs_inversion_alpha.png b/packages/SystemUI/res/drawable-hdpi/ic_qs_inversion_alpha.png Binary files differnew file mode 100644 index 0000000..aea75c1 --- /dev/null +++ b/packages/SystemUI/res/drawable-hdpi/ic_qs_inversion_alpha.png diff --git a/packages/SystemUI/res/drawable-ldpi/ic_qs_color_space_alpha.png b/packages/SystemUI/res/drawable-ldpi/ic_qs_color_space_alpha.png Binary files differnew file mode 100644 index 0000000..46d2a16 --- /dev/null +++ b/packages/SystemUI/res/drawable-ldpi/ic_qs_color_space_alpha.png diff --git a/packages/SystemUI/res/drawable-ldpi/ic_qs_contrast_alpha.png b/packages/SystemUI/res/drawable-ldpi/ic_qs_contrast_alpha.png Binary files differnew file mode 100644 index 0000000..704b4ec --- /dev/null +++ b/packages/SystemUI/res/drawable-ldpi/ic_qs_contrast_alpha.png diff --git a/packages/SystemUI/res/drawable-ldpi/ic_qs_inversion_alpha.png b/packages/SystemUI/res/drawable-ldpi/ic_qs_inversion_alpha.png Binary files differnew file mode 100644 index 0000000..d56efb5 --- /dev/null +++ b/packages/SystemUI/res/drawable-ldpi/ic_qs_inversion_alpha.png diff --git a/packages/SystemUI/res/drawable-mdpi/ic_qs_color_space_alpha.png b/packages/SystemUI/res/drawable-mdpi/ic_qs_color_space_alpha.png Binary files differnew file mode 100644 index 0000000..18b6029 --- /dev/null +++ b/packages/SystemUI/res/drawable-mdpi/ic_qs_color_space_alpha.png diff --git a/packages/SystemUI/res/drawable-mdpi/ic_qs_contrast_alpha.png b/packages/SystemUI/res/drawable-mdpi/ic_qs_contrast_alpha.png Binary files differnew file mode 100644 index 0000000..a4dd087 --- /dev/null +++ b/packages/SystemUI/res/drawable-mdpi/ic_qs_contrast_alpha.png diff --git a/packages/SystemUI/res/drawable-mdpi/ic_qs_inversion_alpha.png b/packages/SystemUI/res/drawable-mdpi/ic_qs_inversion_alpha.png Binary files differnew file mode 100644 index 0000000..b6ea14e --- /dev/null +++ b/packages/SystemUI/res/drawable-mdpi/ic_qs_inversion_alpha.png diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_qs_color_space_alpha.png b/packages/SystemUI/res/drawable-xhdpi/ic_qs_color_space_alpha.png Binary files differnew file mode 100644 index 0000000..95cf67f --- /dev/null +++ b/packages/SystemUI/res/drawable-xhdpi/ic_qs_color_space_alpha.png diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_qs_contrast_alpha.png b/packages/SystemUI/res/drawable-xhdpi/ic_qs_contrast_alpha.png Binary files differnew file mode 100644 index 0000000..9331e52 --- /dev/null +++ b/packages/SystemUI/res/drawable-xhdpi/ic_qs_contrast_alpha.png diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_qs_inversion_alpha.png b/packages/SystemUI/res/drawable-xhdpi/ic_qs_inversion_alpha.png Binary files differnew file mode 100644 index 0000000..efd8b9e --- /dev/null +++ b/packages/SystemUI/res/drawable-xhdpi/ic_qs_inversion_alpha.png diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_qs_color_space_alpha.png b/packages/SystemUI/res/drawable-xxhdpi/ic_qs_color_space_alpha.png Binary files differnew file mode 100644 index 0000000..7f441c8 --- /dev/null +++ b/packages/SystemUI/res/drawable-xxhdpi/ic_qs_color_space_alpha.png diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_qs_contrast_alpha.png b/packages/SystemUI/res/drawable-xxhdpi/ic_qs_contrast_alpha.png Binary files differnew file mode 100644 index 0000000..82c3842 --- /dev/null +++ b/packages/SystemUI/res/drawable-xxhdpi/ic_qs_contrast_alpha.png diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_qs_inversion_alpha.png b/packages/SystemUI/res/drawable-xxhdpi/ic_qs_inversion_alpha.png Binary files differnew file mode 100644 index 0000000..ce9bae2 --- /dev/null +++ b/packages/SystemUI/res/drawable-xxhdpi/ic_qs_inversion_alpha.png diff --git a/packages/SystemUI/res/drawable/ic_qs_color_space_off.xml b/packages/SystemUI/res/drawable/ic_qs_color_space_off.xml new file mode 100644 index 0000000..cf34ba6 --- /dev/null +++ b/packages/SystemUI/res/drawable/ic_qs_color_space_off.xml @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- + Copyright (C) 2014 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<bitmap xmlns:android="http://schemas.android.com/apk/res/android" + android:src="@drawable/ic_qs_color_space_alpha" + android:tint="@color/ic_qs_off" /> diff --git a/packages/SystemUI/res/drawable/ic_qs_color_space_on.xml b/packages/SystemUI/res/drawable/ic_qs_color_space_on.xml new file mode 100644 index 0000000..1806688 --- /dev/null +++ b/packages/SystemUI/res/drawable/ic_qs_color_space_on.xml @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- + Copyright (C) 2014 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<bitmap xmlns:android="http://schemas.android.com/apk/res/android" + android:src="@drawable/ic_qs_color_space_alpha" + android:tint="@color/ic_qs_on" /> diff --git a/packages/SystemUI/res/drawable/ic_qs_contrast_off.xml b/packages/SystemUI/res/drawable/ic_qs_contrast_off.xml new file mode 100644 index 0000000..5f65d8a --- /dev/null +++ b/packages/SystemUI/res/drawable/ic_qs_contrast_off.xml @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- + Copyright (C) 2014 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<bitmap xmlns:android="http://schemas.android.com/apk/res/android" + android:src="@drawable/ic_qs_contrast_alpha" + android:tint="@color/ic_qs_off" /> diff --git a/packages/SystemUI/res/drawable/ic_qs_contrast_on.xml b/packages/SystemUI/res/drawable/ic_qs_contrast_on.xml new file mode 100644 index 0000000..a018929 --- /dev/null +++ b/packages/SystemUI/res/drawable/ic_qs_contrast_on.xml @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- + Copyright (C) 2014 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<bitmap xmlns:android="http://schemas.android.com/apk/res/android" + android:src="@drawable/ic_qs_contrast_alpha" + android:tint="@color/ic_qs_on" /> diff --git a/packages/SystemUI/res/drawable/ic_qs_inversion_off.xml b/packages/SystemUI/res/drawable/ic_qs_inversion_off.xml new file mode 100644 index 0000000..9018a90 --- /dev/null +++ b/packages/SystemUI/res/drawable/ic_qs_inversion_off.xml @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- + Copyright (C) 2014 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<bitmap xmlns:android="http://schemas.android.com/apk/res/android" + android:src="@drawable/ic_qs_inversion_alpha" + android:tint="@color/ic_qs_off" /> diff --git a/packages/SystemUI/res/drawable/ic_qs_inversion_on.xml b/packages/SystemUI/res/drawable/ic_qs_inversion_on.xml new file mode 100644 index 0000000..9110201 --- /dev/null +++ b/packages/SystemUI/res/drawable/ic_qs_inversion_on.xml @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- + Copyright (C) 2014 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<bitmap xmlns:android="http://schemas.android.com/apk/res/android" + android:src="@drawable/ic_qs_inversion_alpha" + android:tint="@color/ic_qs_on" /> diff --git a/packages/SystemUI/res/values/colors.xml b/packages/SystemUI/res/values/colors.xml index e525fbb..5cf0453 100644 --- a/packages/SystemUI/res/values/colors.xml +++ b/packages/SystemUI/res/values/colors.xml @@ -39,4 +39,10 @@ <color name="status_bar_clock_color">#FFFFFFFF</color> <drawable name="notification_item_background_color">#ff111111</drawable> <drawable name="notification_item_background_color_pressed">#ff454545</drawable> + + <!-- Tint color for inactive Quick Settings icons. --> + <color name="ic_qs_off">#ff404040</color> + + <!-- Tint color for active Quick Settings icons. --> + <color name="ic_qs_on">#ffffffff</color> </resources> diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/QuickSettingsModel.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/QuickSettingsModel.java index 48ee1ce..174cad8 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/QuickSettingsModel.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/QuickSettingsModel.java @@ -996,8 +996,8 @@ class QuickSettingsModel implements BluetoothStateChangeCallback, mInversionState.toggled = enabled; mInversionState.type = type; // TODO: Add real icon assets. - mInversionState.iconId = enabled ? R.drawable.ic_qs_bluetooth_on - : R.drawable.ic_qs_bluetooth_off; + mInversionState.iconId = enabled ? R.drawable.ic_qs_inversion_on + : R.drawable.ic_qs_inversion_off; mInversionState.label = res.getString(R.string.quick_settings_inversion_label); mInversionCallback.refreshView(mInversionTile, mInversionState); } @@ -1026,8 +1026,8 @@ class QuickSettingsModel implements BluetoothStateChangeCallback, mContrastState.contrast = contrast; mContrastState.brightness = brightness; // TODO: Add real icon assets. - mContrastState.iconId = enabled ? R.drawable.ic_qs_bluetooth_on - : R.drawable.ic_qs_bluetooth_off; + mContrastState.iconId = enabled ? R.drawable.ic_qs_contrast_on + : R.drawable.ic_qs_contrast_off; mContrastState.label = res.getString(R.string.quick_settings_contrast_label); mContrastCallback.refreshView(mContrastTile, mContrastState); } @@ -1053,8 +1053,8 @@ class QuickSettingsModel implements BluetoothStateChangeCallback, mColorSpaceState.toggled = enabled; mColorSpaceState.type = type; // TODO: Add real icon assets. - mColorSpaceState.iconId = enabled ? R.drawable.ic_qs_bluetooth_on - : R.drawable.ic_qs_bluetooth_off; + mColorSpaceState.iconId = enabled ? R.drawable.ic_qs_color_space_on + : R.drawable.ic_qs_color_space_off; mColorSpaceState.label = res.getString(R.string.quick_settings_color_space_label); mColorSpaceCallback.refreshView(mColorSpaceTile, mColorSpaceState); } |
