Search in sources :

Example 6 with ProgressIndicator

use of javafx.scene.control.ProgressIndicator in project POL-POM-5 by PlayOnLinux.

the class StepRepresentationSpin method drawStepContent.

@Override
protected void drawStepContent() {
    super.drawStepContent();
    Region spacerAbove = new Region();
    VBox.setVgrow(spacerAbove, Priority.ALWAYS);
    this.addToContentPane(spacerAbove);
    ProgressIndicator progressIndicator = new ProgressIndicator();
    this.addToContentPane(progressIndicator);
    Region spacerBelow = new Region();
    VBox.setVgrow(spacerBelow, Priority.ALWAYS);
    this.addToContentPane(spacerBelow);
}
Also used : ProgressIndicator(javafx.scene.control.ProgressIndicator) Region(javafx.scene.layout.Region)

Example 7 with ProgressIndicator

use of javafx.scene.control.ProgressIndicator in project JFoenix by jfoenixadmin.

the class JFXProgressBarSkin method createIndeterminateTimeline.

@Override
protected void createIndeterminateTimeline() {
    super.createIndeterminateTimeline();
    if (indeterminateTransition != null)
        indeterminateTransition.stop();
    ProgressIndicator control = getSkinnable();
    final double w = control.getWidth() - (snappedLeftInset() + snappedRightInset());
    final double bWidth = bar.getWidth();
    indeterminateTransition = new Timeline(new KeyFrame(Duration.ZERO, new KeyValue(bar.scaleXProperty(), 0, Interpolator.EASE_IN), new KeyValue(bar.translateXProperty(), -bWidth, Interpolator.LINEAR)), new KeyFrame(Duration.seconds(0.5), new KeyValue(bar.scaleXProperty(), 3, Interpolator.LINEAR), new KeyValue(bar.translateXProperty(), w / 2, Interpolator.LINEAR)), new KeyFrame(Duration.seconds(1), new KeyValue(bar.scaleXProperty(), 0, Interpolator.EASE_OUT), new KeyValue(bar.translateXProperty(), w, Interpolator.LINEAR)));
    indeterminateTransition.setCycleCount(Timeline.INDEFINITE);
}
Also used : Timeline(javafx.animation.Timeline) KeyValue(javafx.animation.KeyValue) ProgressIndicator(javafx.scene.control.ProgressIndicator) KeyFrame(javafx.animation.KeyFrame)

Example 8 with ProgressIndicator

use of javafx.scene.control.ProgressIndicator in project jabref by JabRef.

the class MathSciNetPaneView method getPane.

StackPane getPane() {
    StackPane root = new StackPane();
    ProgressIndicator progress = new ProgressIndicator();
    progress.setMaxSize(100, 100);
    WebView browser = new WebView();
    // Quick hack to disable navigating
    browser.addEventFilter(javafx.scene.input.MouseEvent.ANY, javafx.scene.input.MouseEvent::consume);
    browser.setContextMenuEnabled(false);
    root.getChildren().addAll(browser, progress);
    mathSciNetId.getExternalURI().ifPresent(url -> browser.getEngine().load(url.toASCIIString()));
    // Hide progress indicator if finished (over 70% loaded)
    browser.getEngine().getLoadWorker().progressProperty().addListener((observable, oldValue, newValue) -> {
        if (newValue.doubleValue() >= 0.7) {
            progress.setVisible(false);
        }
    });
    return root;
}
Also used : ProgressIndicator(javafx.scene.control.ProgressIndicator) WebView(javafx.scene.web.WebView) StackPane(javafx.scene.layout.StackPane)

Example 9 with ProgressIndicator

use of javafx.scene.control.ProgressIndicator in project TeachingInSimulation by ScOrPiOzzy.

the class PageController method showLoading.

/**
 * Show the loading process.
 */
@FxThread
public void showLoading() {
    loadingLayer.setVisible(true);
    loadingLayer.toFront();
    progressIndicator = new ProgressIndicator(ProgressIndicator.INDETERMINATE_PROGRESS);
    progressIndicator.setPrefSize(50, 50);
    // progressIndicator.setId(CssIds.EDITOR_LOADING_PROGRESS);
    loadingLayer.getChildren().add(progressIndicator);
    container.setDisable(true);
    back.setDisable(true);
    setLoading(true);
}
Also used : ProgressIndicator(javafx.scene.control.ProgressIndicator) FxThread(com.cas.sim.tis.anno.FxThread)

Example 10 with ProgressIndicator

use of javafx.scene.control.ProgressIndicator in project POL-POM-5 by PlayOnLinux.

the class FeaturePanelSkin method createWaitPanel.

/**
 * Creates a panel containing a "waiting" indicator
 *
 * @return A panel containing a "waiting" indicator
 */
private HBox createWaitPanel() {
    final ProgressIndicator progressIndicator = new ProgressIndicator();
    progressIndicator.getStyleClass().add("waiting-indicator");
    final HBox waitPanel = new HBox(progressIndicator);
    waitPanel.getStyleClass().add("rightPane");
    return waitPanel;
}
Also used : HBox(javafx.scene.layout.HBox) ProgressIndicator(javafx.scene.control.ProgressIndicator)

Aggregations

ProgressIndicator (javafx.scene.control.ProgressIndicator)11 Region (javafx.scene.layout.Region)3 HBox (javafx.scene.layout.HBox)2 FxThread (com.cas.sim.tis.anno.FxThread)1 InvocationTargetException (java.lang.reflect.InvocationTargetException)1 Method (java.lang.reflect.Method)1 KeyFrame (javafx.animation.KeyFrame)1 KeyValue (javafx.animation.KeyValue)1 Timeline (javafx.animation.Timeline)1 Task (javafx.concurrent.Task)1 JFXPanel (javafx.embed.swing.JFXPanel)1 Label (javafx.scene.control.Label)1 StackPane (javafx.scene.layout.StackPane)1 VBox (javafx.scene.layout.VBox)1 WebView (javafx.scene.web.WebView)1 SearchAlgorithm (org.kanonizo.algorithms.SearchAlgorithm)1 Prerequisite (org.kanonizo.annotations.Prerequisite)1