<AWT Dev> Replacement for com.apple.eawt.FullScreen*

DRC drc at virtualgl.org
Wed Jul 24 21:03:42 UTC 2019

As far as filing a bug report, I would love to, but the rules for
obtaining a bug tracker account are rather stringent, and I doubt that I
qualify (https://wiki.openjdk.java.net/display/general/JBS+Overview).  I
am an application developer that relies upon OpenJDK, and I have some
familiarity with the source code vis-a-vis diagnosing issues such as
this, but I'm not an OpenJDK author.  Sorry if this is the wrong forum
for me to post issues like this, but I didn't know where else to post.

On 7/22/19 4:58 PM, Sergey Bylokhov wrote:
> Hi, DRC.
> I guess this feature have to be implemented by this CR:
> https://bugs.openjdk.java.net/browse/JDK-8143914
> The idea was to use the sequence of: "setExtendedState() + MAXIMIZED_BOTH"
> to toggle the "fullscreen" window. And use the client property to
> enable/disable
> this functionality. But it looks like something has changed since then, and
> the window does not move to the "fullscreen" when we zoom it.
> Please file a bug for this.
> Interesting that the "fullscreen" works fine if the user clicks on the
> zoom button.
> On 20/07/2019 17:03, DRC wrote:
>> I've been beating my head against the wall about this for quite a while,
>> but I can't figure out how to programmatically toggle "Lion Full-Screen
>> Mode" (i.e. "Full-Screen Mode Using Spaces") on macOS without using the
>> deprecated com.apple.eawt.FullScreen* classes, which are problematic at
>> best when including a custom JRE in my app using jlink.  I looked at the
>> OpenJDK 12 source, and it doesn't appear that the native code to do this
>> toggling has any other touch points besides the
>> com.apple.eawt.FullScreen* classes.  What am I missing?  The problem is
>> that, because I'm writing a remote desktop client, I have to provide
>> users with a way to switch in and out of full-screen mode with a
>> keystroke and menu option, and I also have to be able to detect when the
>> user clicks the full-screen button in the window's titlebar.  I don't
>> know how to do that without invoking
>> com.apple.eawt.FullScreenListener.addFullScreenListenerTo() and
>> com.apple.eawt.Application.requestToggleFullScreen().  Any advice is
>> appreciated.
>> DRC

More information about the awt-dev mailing list