Package javafx.animation

Examples of javafx.animation.KeyFrame


         public void handle(ActionEvent ae)
         {
            fadeout.playFromStart();
         }
      };
      kf[0] = new KeyFrame(Duration.valueOf("4000ms"), eh);
      timeline.getKeyFrames().addAll(kf);
   }
View Full Code Here


        validatorMap.get(NODE).alphaProperty().addListener(observable -> { draw(); });

        KeyValue keyValueVisible   = new KeyValue(validatorMap.get(NODE).alphaProperty(), 1);
        KeyValue keyValueInvisible = new KeyValue(validatorMap.get(NODE).alphaProperty(), 0, Interpolator.EASE_IN);

        KeyFrame kf1 = new KeyFrame(Duration.millis(0), keyValueVisible);
        KeyFrame kf2 = new KeyFrame(Duration.millis(1000), keyValueVisible);
        KeyFrame kf3 = new KeyFrame(Duration.millis(1500), keyValueInvisible);

        Timeline timeline = new Timeline();
        timeline.getKeyFrames().setAll(kf1, kf2, kf3);
        faderMap.put(NODE, timeline);
        timeline.setOnFinished(actionEvent -> { faderMap.remove(NODE); });
View Full Code Here

    int refreshMillis = 1000;

    final Duration oneFrameAmt = Duration.millis(refreshMillis);

    final KeyFrame oneFrame = new KeyFrame(oneFrameAmt, new EventHandler<ActionEvent>()
    {
      @Override
      public void handle(ActionEvent arg0)
      {
        refresh();
View Full Code Here

    Scene scene = new Scene(borderPane, 500, 450);
    setScene(scene);

    _controller.execute("games", new Object[] { "default", _user });

    refreshTimeLine = new Timeline(new KeyFrame(Duration.seconds(300),
        new EventHandler<ActionEvent>() {

          @Override
          public void handle(ActionEvent event) {
            _controller.execute("refreshRoom",
View Full Code Here

        if ((int) currentMinuteAngle.get() == 354 && ANGLE == 0) {
            kv = new KeyValue(currentMinuteAngle, 360, Interpolator.SPLINE(0.5, 0.4, 0.4, 1.0));
        } else if ((int) currentMinuteAngle.get() == 0 && ANGLE == 354) {
            kv = new KeyValue(currentMinuteAngle, -6, Interpolator.SPLINE(0.5, 0.4, 0.4, 1.0));
        }       
        final KeyFrame kf = new KeyFrame(Duration.millis(200), kv);
        timeline = new Timeline();
        timeline.getKeyFrames().add(kf);
        timeline.setOnFinished(event -> {
            if ((int) currentMinuteAngle.get() == 360) {
                currentMinuteAngle.set(0);
View Full Code Here

        KeyValue kvO4  = new KeyValue(NODE.opacityProperty(), 1.0, Interpolator.EASE_OUT);

        KeyValue kvX5  = new KeyValue(NODE.translateXProperty(), X);
        KeyValue kvY5  = new KeyValue(NODE.translateYProperty(), Y);

        KeyFrame kfO1  = new KeyFrame(Duration.millis(0), kvX1, kvY1, kvR1, kvO1);
        KeyFrame kfO2  = new KeyFrame(Duration.millis(50 + DELAY), kvX2, kvY2);
        KeyFrame kfO3  = new KeyFrame(Duration.millis(250 + DELAY), kvX3, kvY3);
        KeyFrame kfO4  = new KeyFrame(Duration.millis(400 + DELAY), kvX4, kvY4, kvRO4, kvO4);
        KeyFrame kfO5  = new KeyFrame(Duration.millis(550 + DELAY), kvX5, kvY5);

        return new Timeline(kfO1, kfO2, kfO3, kfO4, kfO5);
    }
View Full Code Here

        KeyValue kvR5  = new KeyValue(NODE.rotateProperty(), 0, Interpolator.EASE_OUT);
        KeyValue kvO5  = new KeyValue(NODE.opacityProperty(), 0.5);

        KeyValue kvO6  = new KeyValue(NODE.opacityProperty(), 0);

        KeyFrame kfC1  = new KeyFrame(Duration.millis(0), kvX1, kvY1);
        KeyFrame kfC2  = new KeyFrame(Duration.millis(50 + DELAY), kvRC2);
        KeyFrame kfC3  = new KeyFrame(Duration.millis(250 + DELAY), kvX3, kvY3);
        KeyFrame kfC4  = new KeyFrame(Duration.millis(400 + DELAY), kvX4, kvY4);
        KeyFrame kfC5  = new KeyFrame(Duration.millis(550 + DELAY), kvX5, kvY5, kvR5, kvO5);
        KeyFrame kfC6  = new KeyFrame(Duration.millis(551 + DELAY), kvO6);

        return new Timeline(kfC1, kfC2, kfC3, kfC4, kfC5, kfC6);
    }
View Full Code Here

        KeyValue kvO4  = new KeyValue(NODE.opacityProperty(), 1.0, Interpolator.EASE_OUT);

        KeyValue kvX5  = new KeyValue(NODE.translateXProperty(), X);
        KeyValue kvY5  = new KeyValue(NODE.translateYProperty(), Y);

        KeyFrame kfO1  = new KeyFrame(Duration.millis(0), kvX1, kvY1, kvO1);
        KeyFrame kfO2  = new KeyFrame(Duration.millis(50 + DELAY), kvX2, kvY2);       
        KeyFrame kfO4  = new KeyFrame(Duration.millis(400 + DELAY), kvX4, kvY4, kvO4);
        KeyFrame kfO5  = new KeyFrame(Duration.millis(500 + DELAY), kvX5, kvY5);

        return new Timeline(kfO1, kfO2, kfO4, kfO5);
    }
View Full Code Here

        KeyValue kvY5  = new KeyValue(NODE.translateYProperty(), 0, Interpolator.EASE_OUT);
        KeyValue kvO5  = new KeyValue(NODE.opacityProperty(), 0.5);

        KeyValue kvO6  = new KeyValue(NODE.opacityProperty(), 0);

        KeyFrame kfC1  = new KeyFrame(Duration.millis(0), kvX1, kvY1);
        KeyFrame kfC3  = new KeyFrame(Duration.millis(0 + DELAY), kvX3, kvY3);
        KeyFrame kfC4  = new KeyFrame(Duration.millis(350 + DELAY), kvX4, kvY4);
        KeyFrame kfC5  = new KeyFrame(Duration.millis(500 + DELAY), kvX5, kvY5, kvO5);
        KeyFrame kfC6  = new KeyFrame(Duration.millis(501 + DELAY), kvO6);

        return new Timeline(kfC1, kfC3, kfC4, kfC5, kfC6);
    }
View Full Code Here

        if (nextSelectionIndex >= selectedSet.size()) {
            nextSelectionIndex = 0;
        }
        //keyValueFlap = new KeyValue(rotateFlap.angleProperty(), 180, Interpolator.SPLINE(0.5, 0.4, 0.4, 1.0));
        keyValueFlap = new KeyValue(rotateFlap.angleProperty(), 180, Interpolator.EASE_IN);
        keyFrame     = new KeyFrame(Duration.millis(getSkinnable().getFlipTime()), keyValueFlap);
        timeline.getKeyFrames().setAll(keyFrame);
        timeline.play();
    }
View Full Code Here

TOP

Related Classes of javafx.animation.KeyFrame

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.