JDK-8093691 : Iconifying a maximized window corrupts iconifiedProperty
  • Type: Bug
  • Component: javafx
  • Sub-Component: window-toolkit
  • Affected Version: 8u45
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • Submitted: 2015-06-01
  • Updated: 2015-06-12
  • Resolved: 2015-06-03
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 9
9Resolved
Related Reports
Duplicate :  
Description
Iconifying and restoring a stage by clicking on the taskbar icon works fine.
However, if the stage is maximized, iconifying only works once; after restoring the stage the iconifyProperty isn't update, also it's not updated when iconifying again. Only after un-maximizing the stage, the behavior returns to normal-

{code}
public class Main extends Application {

  @Override
  public void start(Stage primaryStage) throws Exception {
    VBox root = new VBox();

    Button iconifyButton = new Button("Iconify");
    iconifyButton.setOnAction(event -> primaryStage.setIconified(true));

    Button maximizeButton = new Button("Maximize");
    maximizeButton.setOnAction(event -> primaryStage.setMaximized(!primaryStage.isMaximized()));

    root.getChildren().addAll(iconifyButton, maximizeButton);

    primaryStage.iconifiedProperty().addListener((observable, oldValue, newValue) -> {
      System.out.println("Iconified: " + newValue);
    });
    primaryStage.maximizedProperty().addListener((observable, oldValue, newValue) -> {
      System.out.println("Maximized: " + newValue);
    });

    primaryStage.setTitle("Hello World");
    primaryStage.initStyle(StageStyle.UNDECORATED);
    primaryStage.setScene(new Scene(root, 100, 100));
    primaryStage.show();
  }


  public static void main(String[] args) {
    launch(args);
  }
}
{code}
Comments
Correct. didn't find that one.
03-06-2015

Actually after looking more closely I am convinced that this is a duplicate.
03-06-2015

This looks related to RT-36916 (and may be a duplicate).
03-06-2015