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

ProgressIndicator/ProgressBar continue to animate when removed or made invisible

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P3
    • 8u40
    • 8u20
    • javafx

    Description

      It's possible for ProgressIndicators/Bars to "leak" Animations and thus keep the scene pulsing and cpu burning. I wasn't able to figure out why this happens by reading the code, as the right codepaths do seem to be present, but nonetheless if I do setVisible(false) on a parent of an indeterminate ProgressIndicator, or remove the parent of an indeterminate ProgressBar from the scene graph, I can clearly see the animations are still registered in Toolkit.getToolkit().getMasterTimer().receivers and cpu usage remains high.

      My hack around this issue is to set the progress bar/indicator to some definite percentage before it has a chance to be set invisible or removed from the scene graph. This forces it to stop the animation. If I don't do this, the animation stays alive somehow.

      Attachments

        Issue Links

          Activity

            People

              jgiles Jonathan Giles
              mhearnjfx Mike Hearn (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                Imported: