jounikoivuviita/Animator — Issue #8: Size animation moves layout 1px up each time
Author: theaspect
Created: 2012-03-09 06:35:14+00:00
State: open

If we move layout back and forth in X direction it rises 1px up each time. So we need y+=1 to compensate it.

```java
public void onOpenThird() {
view.getAnimator().animate((HorizontalLayout) view, AnimType.SIZE).setDuration(150)
.setData("width=+450,x=-450,y=+1");
view.getAnimator().animate(view.getRightContent(), AnimType.FADE_IN).setDuration(150).setDelay(150);
}
public void onCloseThird() {
view.getAnimator().animate(view.getRightContent(), AnimType.FADE_OUT).setDuration(150);
view.getAnimator().animate((HorizontalLayout) view, AnimType.SIZE).setDuration(150)
.setData("width=-450,x=+450,y=+1").setDelay(150);
}
```