summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher2/AllAppsTabbed.java
diff options
context:
space:
mode:
authorPatrick Dubroy <dubroy@google.com>2010-08-06 16:01:33 -0700
committerPatrick Dubroy <dubroy@google.com>2010-08-09 14:25:36 -0700
commit3ec8bdd576e23f6aa783d5377abecac6fda07374 (patch)
treededa51f09890fae61a5b70ff75ed65e9a8f5d7d1 /src/com/android/launcher2/AllAppsTabbed.java
parent9cf976350b8f07af80884938d539ac538896a583 (diff)
downloadandroid_packages_apps_Trebuchet-3ec8bdd576e23f6aa783d5377abecac6fda07374.tar.gz
android_packages_apps_Trebuchet-3ec8bdd576e23f6aa783d5377abecac6fda07374.tar.bz2
android_packages_apps_Trebuchet-3ec8bdd576e23f6aa783d5377abecac6fda07374.zip
Refactor zooming animation, and apply it to customize drawer too.
Change-Id: I0bbd5a68adc82cea02dc583ac3d04e3de8c0346e
Diffstat (limited to 'src/com/android/launcher2/AllAppsTabbed.java')
-rw-r--r--src/com/android/launcher2/AllAppsTabbed.java13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/com/android/launcher2/AllAppsTabbed.java b/src/com/android/launcher2/AllAppsTabbed.java
index 3aa70f49e..7dbb1a5fa 100644
--- a/src/com/android/launcher2/AllAppsTabbed.java
+++ b/src/com/android/launcher2/AllAppsTabbed.java
@@ -92,10 +92,6 @@ public class AllAppsTabbed extends TabHost implements AllAppsView {
});
setCurrentTab(0);
-
- // It needs to be INVISIBLE so that it will be measured in the layout.
- // Otherwise the animations is messed up when we show it for the first time.
- setVisibility(INVISIBLE);
}
@Override
@@ -113,8 +109,13 @@ public class AllAppsTabbed extends TabHost implements AllAppsView {
// NOTE: animate parameter is ignored for the TabHost itself
setVisibility((zoom == 0.0f) ? View.GONE : View.VISIBLE);
mAllApps2D.zoom(zoom, animate);
- bringChildToFront((View)mAllApps2D);
- getParent().bringChildToFront(this);
+ }
+
+ @Override
+ public void setVisibility(int visibility) {
+ super.setVisibility(visibility);
+ float zoom = visibility == View.VISIBLE ? 1.0f : 0.0f;
+ mAllApps2D.zoom(zoom, false);
}
@Override