summaryrefslogtreecommitdiffstats
path: root/res/animator
diff options
context:
space:
mode:
authorSunny Goyal <sunnygoyal@google.com>2017-02-16 13:33:15 -0800
committerSunny Goyal <sunnygoyal@google.com>2017-02-23 16:15:25 -0800
commit2a76e3fbc654481eb05ac3187896884ad1497b9f (patch)
treec5b1aa7edd31277e487bada373da308e8234c487 /res/animator
parentf28629a47b5fcd9532683e9c9ad7aad049e0106d (diff)
downloadandroid_packages_apps_Trebuchet-2a76e3fbc654481eb05ac3187896884ad1497b9f.tar.gz
android_packages_apps_Trebuchet-2a76e3fbc654481eb05ac3187896884ad1497b9f.tar.bz2
android_packages_apps_Trebuchet-2a76e3fbc654481eb05ac3187896884ad1497b9f.zip
Removing custom state definition from FastBitmapDrawable
> For Fast scrolling, using state list animator defined in xml > For Pressed state, using onState change method in a drawable Change-Id: Ia608690f593938cf0f77e00afcc2a3076e48d8f4
Diffstat (limited to 'res/animator')
-rw-r--r--res/animator/all_apps_fastscroll_icon_anim.xml49
-rw-r--r--res/animator/overview_button_anim.xml42
2 files changed, 91 insertions, 0 deletions
diff --git a/res/animator/all_apps_fastscroll_icon_anim.xml b/res/animator/all_apps_fastscroll_icon_anim.xml
new file mode 100644
index 000000000..380b009a6
--- /dev/null
+++ b/res/animator/all_apps_fastscroll_icon_anim.xml
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright 2017, 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.
+-->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+
+ <item android:state_activated="true">
+ <set>
+ <objectAnimator
+ android:duration="225"
+ android:propertyName="scaleX"
+ android:valueTo="1.15"
+ android:valueType="floatType" />
+ <objectAnimator
+ android:duration="225"
+ android:propertyName="scaleY"
+ android:valueTo="1.15"
+ android:valueType="floatType" />
+ </set>
+ </item>
+
+ <item>
+ <set>
+ <objectAnimator
+ android:duration="275"
+ android:propertyName="scaleX"
+ android:valueTo="1"
+ android:valueType="floatType" />
+ <objectAnimator
+ android:duration="275"
+ android:propertyName="scaleY"
+ android:valueTo="1"
+ android:valueType="floatType" />
+ </set>
+ </item>
+
+</selector> \ No newline at end of file
diff --git a/res/animator/overview_button_anim.xml b/res/animator/overview_button_anim.xml
new file mode 100644
index 000000000..aac3d2655
--- /dev/null
+++ b/res/animator/overview_button_anim.xml
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright 2015, 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.
+-->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+
+ <item android:state_pressed="true">
+ <objectAnimator
+ android:duration="@android:integer/config_shortAnimTime"
+ android:propertyName="alpha"
+ android:valueTo="0.5"
+ android:valueType="floatType" />
+ </item>
+
+ <item android:state_focused="true">
+ <objectAnimator
+ android:duration="@android:integer/config_shortAnimTime"
+ android:propertyName="alpha"
+ android:valueTo="0.5"
+ android:valueType="floatType" />
+ </item>
+ <item>
+ <objectAnimator
+ android:duration="@android:integer/config_shortAnimTime"
+ android:propertyName="alpha"
+ android:valueTo="1"
+ android:valueType="floatType" />
+ </item>
+
+</selector> \ No newline at end of file