Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8151166

Progress Indicator indeterminate transition not stopped when component is not visible

XMLWordPrintable

    • x86_64
    • windows_7

      FULL PRODUCT VERSION :
      java version "1.8.0_73"
      Java(TM) SE Runtime Environment (build 1.8.0_73-b02)
      Java HotSpot(TM) 64-Bit Server VM (build 25.73-b02, mixed mode)

      ADDITIONAL OS VERSION INFORMATION :
      Windows 7 x64

      A DESCRIPTION OF THE PROBLEM :
      When there is a ProgressIndicator in a scene marked as Indeterminated and a parent is set visible= false the transition runs.

      REGRESSION. Last worked in version 7u80

      ADDITIONAL REGRESSION INFORMATION:
      After the listeners refactoring in ProgressIndicatorSkin it was removed a listener to impl_treeVisibleProperty() that was handling the visibility also of the parents.

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      Run the code provided.

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      No transtion runs.
      ACTUAL -
      Transition runs.

      ERROR MESSAGES/STACK TRACES THAT OCCUR :
      In big applications running in 4k Monitors with JFXPanels produces OutOfMemoryExceptions.

      REPRODUCIBILITY :
      This bug can be reproduced always.

      ---------- BEGIN SOURCE ----------
      public class JFXMain extends Application{

          @Override
          public void start(Stage primaryStage) throws Exception {
              HBox root = new HBox();
              ToggleButton toggleButton = new ToggleButton();
              ProgressIndicator progressIndicator = new ProgressIndicator(ProgressIndicator.INDETERMINATE_PROGRESS);
              StackPane stackPane = new StackPane(progressIndicator);
              stackPane.visibleProperty().bind(toggleButton.selectedProperty());
              root.getChildren().addAll(toggleButton, stackPane);
              primaryStage.setScene(new Scene(root));
              primaryStage.show();
          }
      }

      ---------- END SOURCE ----------

      CUSTOMER SUBMITTED WORKAROUND :
      Remove all ProgressInidicators.

      Creating a StackPane als wrapper of a ProgressIndicator that was removed and added depending on the tree visibility was not always enough because the nodes are saved also in the durty list.

            jgiles Jonathan Giles
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: