Moving mState from Workspace to StateManager

Bug: 67678570
Change-Id: I8cdab044d0760fcc4c188830cde4f963d072b907
This commit is contained in:
Sunny Goyal
2017-10-25 15:47:38 -07:00
parent 3e3f44c3ad
commit ea60926c3f
5 changed files with 57 additions and 54 deletions

View File

@@ -161,12 +161,10 @@ public class WorkspaceStateTransitionAnimation {
setWorkspaceProperty(toState, NO_ANIM_PROPERTY_SETTER);
}
public void setStateWithAnimation(LauncherState fromState, LauncherState toState,
AnimatorSet anim, AnimationLayerSet layerViews, AnimationConfig config) {
long duration = config.getDuration(toState == LauncherState.NORMAL
? fromState.transitionDuration : toState.transitionDuration);
public void setStateWithAnimation(LauncherState toState, AnimatorSet anim,
AnimationLayerSet layerViews, AnimationConfig config) {
AnimatedPropertySetter propertySetter =
new AnimatedPropertySetter(duration, layerViews, anim);
new AnimatedPropertySetter(config.duration, layerViews, anim);
setWorkspaceProperty(toState, propertySetter);
}