Package org.jdesktop.animation.timing

Examples of org.jdesktop.animation.timing.Animator$SwingTimingSource


    protected abstract Point getStartPoint(JComponent container, JComponent overlay);
   
    private void startAnimation(JComponent container, JComponent overlay) {
        overlay.putClientProperty(OverlayContainer.ANIMATING_PROPERTY, Boolean.TRUE);
        Animator anim = new Animator(250, new Worker(container, overlay));
        anim.setAcceleration(0.3f);
        anim.setDeceleration(0.2f);
        anim.start();
    }
View Full Code Here


        animator.start();
    }

    private Animator createAnimator(boolean isShow) {
        TimingTargetAdapter behavior = isShow ? new ShowAnimation() : new HideAnimation();
        Animator a = new Animator(duration, behavior);
        if (externalTarget != null) {
            a.addTarget(externalTarget);
        }
        a.setAcceleration(acceleration);
        a.setDeceleration(deceleration);
        return a;
    }
View Full Code Here

    }

    private void startAnimation(int location) {
        animating = true;
        final int currentLocation = getDividerLocation();
        Animator animator = new Animator(250);
        animator.setResolution(15);
        animator.setAcceleration(0.3f);
        animator.setDeceleration(0.2f);
        animator.addTarget(new PropertySetter(this, "dividerLocation", Integer.valueOf(location)));
        animator.addTarget(new TimingTargetAdapter() {

            @Override
            public void end() {
                animating = false;
                isProcessingOneTouch = false;
                setLastDividerLocation(currentLocation);
            }
        });
        animator.start();
    }
View Full Code Here

           
        });
    }
   
    private void animate(TimingTarget target) {
        Animator anim = new Animator(250, target);
        anim.setAcceleration(0.3f);
        anim.setDeceleration(0.2f);
        anim.start();
    }
View Full Code Here

     * cannot be found for propertyName.
     */
    public static Animator createAnimator(int duration, Object object,
            String propertyName, KeyFrames keyFrames) {
        PropertySetter ps = new PropertySetter(object, propertyName, keyFrames);
        Animator animator = new Animator(duration, ps);
        return animator;
    }
View Full Code Here

     * cannot be found for propertyName.
     */
    public static <T> Animator createAnimator(int duration,
            Object object, String propertyName, T... params) {
        PropertySetter ps = new PropertySetter(object, propertyName, params);
        Animator animator = new Animator(duration, ps);
        return animator;
    }
View Full Code Here

    public static <T> Animator createAnimator(int duration,
            Object object, String propertyName,
            Evaluator evaluator, T... params) {
        PropertySetter ps = new PropertySetter(object, propertyName, evaluator,
                params);
        Animator animator = new Animator(duration, ps);
        return animator;
    }
View Full Code Here

            if (template != null) {
                if (controller != null && controller.isRunning()) {
                    controller.stop();
                }

                controller = new Animator(300,
                        new PropertySetter(display, "control1",
                        point2dInterpolator, display.getControl1(),
                        template.getControl1()));
                controller.setResolution(10);
                controller.addTarget(new PropertySetter(display, "control2",
View Full Code Here

TOP

Related Classes of org.jdesktop.animation.timing.Animator$SwingTimingSource

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.