summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/LauncherStateTransitionAnimation.java
diff options
context:
space:
mode:
authorHyunyoung Song <hyunyoungs@google.com>2015-04-17 19:02:30 -0700
committerHyunyoung Song <hyunyoungs@google.com>2015-04-19 19:25:49 -0700
commit4cea4c830283e017fc36197cfe9d7ce713aec49d (patch)
tree786e402b2d907cb468ade930ce7a9643ca6b742c /src/com/android/launcher3/LauncherStateTransitionAnimation.java
parent7af216ff04b7f0c3852119b476d8f692edfcaaa7 (diff)
downloadandroid_packages_apps_Trebuchet-4cea4c830283e017fc36197cfe9d7ce713aec49d.tar.gz
android_packages_apps_Trebuchet-4cea4c830283e017fc36197cfe9d7ce713aec49d.tar.bz2
android_packages_apps_Trebuchet-4cea4c830283e017fc36197cfe9d7ce713aec49d.zip
WidgetTray UI tweak
- set fixed image view width - fade in when widget bitmap populates - widget dimension is next to the widget name text. - elevation of the widgets content and the reveal view is the same b/19897708 Change-Id: Ia656144412e7d63a491ce67ff15fb58c05d9a9d9
Diffstat (limited to 'src/com/android/launcher3/LauncherStateTransitionAnimation.java')
-rw-r--r--src/com/android/launcher3/LauncherStateTransitionAnimation.java20
1 files changed, 16 insertions, 4 deletions
diff --git a/src/com/android/launcher3/LauncherStateTransitionAnimation.java b/src/com/android/launcher3/LauncherStateTransitionAnimation.java
index 78272a8ec..8ba5c60f3 100644
--- a/src/com/android/launcher3/LauncherStateTransitionAnimation.java
+++ b/src/com/android/launcher3/LauncherStateTransitionAnimation.java
@@ -182,8 +182,14 @@ public class LauncherStateTransitionAnimation {
*/
public void startAnimationToWidgets(final boolean animated) {
final WidgetsContainerView toView = mLauncher.getWidgetsView();
+ final Resources res = mLauncher.getResources();
PrivateTransitionCallbacks cb = new PrivateTransitionCallbacks() {
@Override
+ public void onRevealViewVisible(View revealView, View contentView,
+ View allAppsButtonView) {
+ revealView.setBackground(res.getDrawable(R.drawable.quantum_panel_dark));
+ }
+ @Override
public float getMaterialRevealViewFinalAlpha(View revealView) {
return 0.3f;
}
@@ -192,8 +198,9 @@ public class LauncherStateTransitionAnimation {
return revealView.getMeasuredHeight() / 2;
}
};
- startAnimationToOverlay(Workspace.State.OVERVIEW_HIDDEN, toView, toView.getContentView(),
- toView.getRevealView(), animated, true /* hideSearchBar */, cb);
+ startAnimationToOverlay(Workspace.State.OVERVIEW_HIDDEN, toView,
+ toView.getContentView(), toView.getRevealView(), animated, true /* hideSearchBar */,
+ cb);
}
/**
@@ -386,7 +393,6 @@ public class LauncherStateTransitionAnimation {
mStateAnimation.start();
}
};
-
toView.bringToFront();
toView.setVisibility(View.VISIBLE);
toView.post(startAnimRunnable);
@@ -481,9 +487,15 @@ public class LauncherStateTransitionAnimation {
private void startAnimationToWorkspaceFromWidgets(final Launcher.State fromState,
final Workspace.State toWorkspaceState, final boolean animated,
final Runnable onCompleteRunnable) {
- WidgetsContainerView widgetsView = mLauncher.getWidgetsView();
+ final WidgetsContainerView widgetsView = mLauncher.getWidgetsView();
+ final Resources res = mLauncher.getResources();
PrivateTransitionCallbacks cb = new PrivateTransitionCallbacks() {
@Override
+ public void onRevealViewVisible(View revealView, View contentView,
+ View allAppsButtonView) {
+ revealView.setBackground(res.getDrawable(R.drawable.quantum_panel_dark));
+ }
+ @Override
public float getMaterialRevealViewFinalYDrift(View revealView) {
return revealView.getMeasuredHeight() / 2;
}