Hi Jeremy,

Does any of the following options help in your case to determine whether or not 
the frame is iconified?


  1.  frame.isActive()
  2.  frame.isFocused()
  3.  frame.isAlwaysOnTop()

Thanks & Regards,
Harshitha Onkar

From: client-libs-dev <[email protected]> On Behalf Of Jeremy 
Wood
Sent: Wednesday, February 15, 2023 10:08 PM
To: [email protected]
Subject: Stage Manager Problems

We’re experiencing problems related JFrames while Stage 
Manager<https://www.computerworld.com/article/3667999/what-is-apple-stage-manager-and-how-is-it-used.html>
 is active Mac.

When Stage Manager is active the yellow minimize button on our JFrame’s appears 
to “minimize” our app. But as far as our Frame is concerned:
1. Frame.getExtendedState() does not indicate we’re in an ICONIFIED state
2. Frame.isShowing() returns true
3. a java.awt.desktop.AppForegroundListener believes our app is in the 
foreground.

We want to identify when we’re in this hidden state. Is there any other 
property we can consult to help identify this state?

I’m happy to submit an openjdk ticket if needed, but first I wanted to sanity 
check that I’m not missing something. (I also tried 
querying<https://bugs.openjdk.org/issues/?jql=text%20~%20%22%5C%22Stage%20Manager%5C%22%22>
 the openJDK bug database, but didn’t see any hits.)

I tried rummaging around in Mac-specific classes (like CPlatformWindow), but I 
didn’t see any promising leads. It’s always possible I missed something, though.

Attached is a small 200-line demo app.

Reply via email to