use of javafx.animation.Timeline in project cryptomator by cryptomator.
the class UnlockedController method startIoSampling.
// ****************************************
// IO Graph
// ****************************************
private void startIoSampling() {
final Series<Number, Number> decryptedBytes = new Series<>();
decryptedBytes.setName(localization.getString("unlocked.label.statsDecrypted"));
final Series<Number, Number> encryptedBytes = new Series<>();
encryptedBytes.setName(localization.getString("unlocked.label.statsEncrypted"));
ioGraph.getData().add(decryptedBytes);
ioGraph.getData().add(encryptedBytes);
ioAnimation = new Timeline();
ioAnimation.getKeyFrames().add(new KeyFrame(Duration.seconds(IO_SAMPLING_INTERVAL), new IoSamplingAnimationHandler(decryptedBytes, encryptedBytes)));
ioAnimation.setCycleCount(Animation.INDEFINITE);
ioAnimation.play();
}
use of javafx.animation.Timeline in project fxexperience2 by EricCanull.
the class FadeOutLeftBigTransition method starting.
@Override
protected void starting() {
double endX = -node.localToScene(0, 0).getX() - node.getBoundsInParent().getWidth();
timeline = new Timeline(new KeyFrame(Duration.millis(0), new KeyValue(node.opacityProperty(), 1, WEB_EASE), new KeyValue(node.translateXProperty(), 0, WEB_EASE)), new KeyFrame(Duration.millis(1000), new KeyValue(node.opacityProperty(), 0, WEB_EASE), new KeyValue(node.translateXProperty(), endX, WEB_EASE)));
super.starting();
}
use of javafx.animation.Timeline in project fxexperience2 by EricCanull.
the class FadeOutUpBigTransition method starting.
@Override
protected void starting() {
double endY = -node.localToScene(0, 0).getY() - node.getBoundsInParent().getHeight();
timeline = new Timeline(new KeyFrame(Duration.millis(0), new KeyValue(node.opacityProperty(), 1, WEB_EASE), new KeyValue(node.translateYProperty(), 0, WEB_EASE)), new KeyFrame(Duration.millis(1000), new KeyValue(node.opacityProperty(), 0, WEB_EASE), new KeyValue(node.translateYProperty(), endY, WEB_EASE)));
super.starting();
}
use of javafx.animation.Timeline in project fxexperience2 by EricCanull.
the class RollOutTransition method starting.
@Override
protected void starting() {
super.starting();
timeline = new Timeline(new KeyFrame(Duration.millis(0), new KeyValue(node.opacityProperty(), 1, WEB_EASE), new KeyValue(node.translateXProperty(), 0, WEB_EASE), new KeyValue(node.rotateProperty(), 0, WEB_EASE)), new KeyFrame(Duration.millis(1000), new KeyValue(node.opacityProperty(), 0, WEB_EASE), new KeyValue(node.translateXProperty(), node.getBoundsInLocal().getWidth(), WEB_EASE), new KeyValue(node.rotateProperty(), 120, WEB_EASE)));
}
use of javafx.animation.Timeline in project fxexperience2 by EricCanull.
the class RotateInDownRightTransition method starting.
@Override
protected void starting() {
super.starting();
rotate = new Rotate(0, node.getBoundsInLocal().getWidth(), node.getBoundsInLocal().getHeight());
timeline = new Timeline(new KeyFrame(Duration.millis(0), new KeyValue(node.opacityProperty(), 0, WEB_EASE), new KeyValue(rotate.angleProperty(), 90, WEB_EASE)), new KeyFrame(Duration.millis(1000), new KeyValue(node.opacityProperty(), 1, WEB_EASE), new KeyValue(rotate.angleProperty(), 0, WEB_EASE)));
node.getTransforms().add(rotate);
}
Aggregations