Search in sources :

Example 1 with SplitterResizedEvent

use of com.google.gwt.user.client.ui.SplitterResizedEvent in project rstudio by rstudio.

the class PaneManager method horizontalResizeAnimation.

private Animation horizontalResizeAnimation(final double start, final double end, final Command afterComplete) {
    return new Animation() {

        @Override
        protected void onUpdate(double progress) {
            double size = (1 - progress) * start + progress * end;
            panel_.setWidgetSize(right_, size);
        }

        @Override
        protected void onStart() {
            isAnimating_ = true;
            super.onStart();
        }

        @Override
        protected void onComplete() {
            isAnimating_ = false;
            panel_.onSplitterResized(new SplitterResizedEvent());
            super.onComplete();
            if (afterComplete != null)
                afterComplete.execute();
        }
    };
}
Also used : SplitterResizedEvent(com.google.gwt.user.client.ui.SplitterResizedEvent) Animation(com.google.gwt.animation.client.Animation)

Aggregations

Animation (com.google.gwt.animation.client.Animation)1 SplitterResizedEvent (com.google.gwt.user.client.ui.SplitterResizedEvent)1