Using Notification leaves ghost window on taskbar

Create issue
Issue #44 new
Ron Siven created an issue

I use the NotifierBuilder to create a notifier, and then create a Notification using the NotificationBuilder. When I invoke the notifier.notify(notification) method, it creates a ghost window on the Windows taskbar that doesn't disappear when the Popup disappears.

    private Notification.Notifier notifier;

    notifier = NotifierBuilder.create()

    Notification errorNotification = NotificationBuilder.create()   
        .title(resourceBundle.getString("title") + " - " + resourceBundle.getString("error"))

    Platform.runLater(() -> notifier.notify(errorNotification));

Comments (12)

  1. Gerrit Grunwald repo owner

    Can you try with last commit? I just modified some minor things but not sure if it has an effect on Windows.

  2. Ron Siven reporter

    Thanks for your timely response! I have a tight timeline for my project, and this notification tool is exactly what I need. So, thank you for that as well!

    I just pulled your changes, and still see the same behavior. What I have done for now is change the showPopup method to hide the stage if the popups list is empty. So, from this:

        timeline.setOnFinished(actionEvent -> Platform.runLater(() -> {
            fireNotificationEvent(new NotificationEvent(NOTIFICATION, Notifier.this, POPUP, NotificationEvent.HIDE_NOTIFICATION));

    to this:

        timeline.setOnFinished(actionEvent -> Platform.runLater(() -> {
            if (popups.isEmpty()) {
            fireNotificationEvent(new NotificationEvent(NOTIFICATION, Notifier.this, POPUP, NotificationEvent.HIDE_NOTIFICATION));

    I also added an icon to the stage. :)

  3. Ron Siven reporter


    It appears as though I'm not the only one. I see that someone else commented about a similar issue a couple of weeks ago on the YouTube video for this feature of Enzo:

    Could it be a Windows 10 thing? I kind of doubt it. It's most likely a Windows or a Java thing. If we could specify more than one StageStyle like TRANSPARENT and UTILITY, this would not be a problem.

    I'm happy to assist in any way I can. I'll keep seeking answers in the meantime unless you find an answer before that.

    Thanks again!

  4. Ron Siven reporter

    This is a total hack. But, by setting stage.setY(-100); and stage.initStyle(StageStyle.UTILITY); in the initGraphics() method of the Notification.Notifier enum, the window doesn't appear on the taskbar. Nor is it visible to the user as it is off of the viewable area of the srceen. ¯_(ツ)_/¯

  5. Gerrit Grunwald repo owner

    Yep I played with the same hack but did not like it much which is the reason why it is not in :) So it seems that this problem only occurs on Windows, problem for me is that I do not have a windows machine available, just OS X and Linux. Will try to find a way...

  6. Gerrit Grunwald repo owner

    You might want to try the following in Notifier:

    private void initGraphics() {
        scene = new Scene(new Region());
        stage = new Stage();
  7. Ron Siven reporter

    I tried the code from above, but to no avail. The window does not appear on the taskbar, but it appears on the desktop as a tiny window with only a close ('X') button.

  8. Log in to comment