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

Exception in Quantum due to null platformWindow

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P4
    • jfx20
    • jfx14, jfx16
    • javafx
    • The problem is reproduceable on both Linux and Mac (Windows cannot be tested) so it should be very generic.

    • b06

    Description

      This happens when a Window is opened while a tooltip is open. The code to reproduce is unfortunately not possible to derive since it is deep into custom code that is not public.
      However, the exception should be pretty self explanatory and a defensive null check should be very safe.

      When the exception happens the UI locks completely and the app will have to be shut down with killall.

      Uncought exception in thread Thread[JavaFX Application Thread,5,main] (Cannot invoke "com.sun.glass.ui.Window.isTransparentWindow()" because the return value of "com.sun.javafx.tk.quantum.WindowStage.getPlatformWindow()" is null)
      java.lang.NullPointerException: Cannot invoke "com.sun.glass.ui.Window.isTransparentWindow()" because the return value of "com.sun.javafx.tk.quantum.WindowStage.getPlatformWindow()" is null
      at com.sun.javafx.tk.quantum.GlassScene.getClearColor(GlassScene.java:334)
      at com.sun.javafx.tk.quantum.SceneState.update(SceneState.java:100)
      at com.sun.javafx.tk.quantum.GlassScene.updateSceneState(GlassScene.java:277)
      at com.sun.javafx.tk.quantum.GlassScene.releaseSynchronization(GlassScene.java:138)
      at javafx.scene.Scene$ScenePulseListener.pulse(Scene.java:2511)
      at com.sun.javafx.tk.Toolkit.lambda$runPulse$2(Toolkit.java:413)
      at java.base/java.security.AccessController.doPrivileged(AccessController.java:391)
      at com.sun.javafx.tk.Toolkit.runPulse(Toolkit.java:412)
      at com.sun.javafx.tk.Toolkit.firePulse(Toolkit.java:439)
      at com.sun.javafx.tk.quantum.QuantumToolkit.pulse(QuantumToolkit.java:563)
      at com.sun.javafx.tk.quantum.QuantumToolkit.pulse(QuantumToolkit.java:543)
      at com.sun.javafx.tk.quantum.QuantumToolkit.pulseFromQueue(QuantumToolkit.java:536)
      at com.sun.javafx.tk.quantum.QuantumToolkit.lambda$runToolkit$11(QuantumToolkit.java:342)
      at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:96)
      at com.sun.glass.ui.gtk.GtkApplication.enterNestedEventLoopImpl(Native Method)
      at com.sun.glass.ui.gtk.GtkApplication._enterNestedEventLoop(GtkApplication.java:347)
      at com.sun.glass.ui.Application.enterNestedEventLoop(Application.java:512)
      at com.sun.glass.ui.EventLoop.enter(EventLoop.java:107)
      at com.sun.javafx.tk.quantum.QuantumToolkit.enterNestedEventLoop(QuantumToolkit.java:635)
      at javafx.stage.Stage.showAndWait(Stage.java:465)

      Attachments

        Issue Links

          Activity

            People

              lkostyra Lukasz Kostyra
              mgrev Mikael Grev
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: