tomivirkki/carousel — pull request #3 by kumm (2013-04-28 16:32:40+00:00)
Title: transition animation fix

Fixes animation when scrollToPanelIndex,
and setCarouselSize called in same event loop

Bug can be reproduced, when you add a new component, and scroll to it in one round, in a fullsized carousel.

HorizontalCarousel c = new HorizontalCarousel();
c.setSizeFull();
c.addComponent(firstchild);
....
....//later in an event listener
c.addComponent(secondchild);
c.requestWidgets(2);
c.scroll(1);

In this case no animation occured. I've not tested fallback mode. I think should work.

Full testcode can be found in my 'testbed' branch, if you are interested.