Accessing JavaFX's StageHelper and ContextMenuContent in Jigsaw

Kevin Rushforth kevin.rushforth at
Fri Nov 6 23:59:58 UTC 2015

To give some additional context, here are some brief comments I wrote on 
jigsaw-dev (before suggesting that this topic move over here).

1) The StageHelper class is deliberately not exposed for good reasons, 
since it's purpose is to provide internal access to non-public state.

2) We moved most of the skin classes to a publicly exported package as part of JEP 253, but that didn't 
include ContextMenuContent.

3) in addition to the two internal classes, you are also accessing a 
non-supported (and not documented) impl_* method which may or may not 
continue to work.

Can you explain what you are trying to do with these classes? Perhaps 
there is an alternative?

-- Kevin

Jonathan Giles wrote:
> Neither of these classes are currently planned to be moved into public 
> API for JDK 9. You should file separate requests in bug tracker so we 
> can discuss the feasibility of both of these classes.
> -- Jonathan
> On 6/11/15 11:48 PM, Rahman USTA wrote:
>> Hi all;
>> I'm trying Jigsaw build with my JavaFX project, everything is fine 
>> but with
>> two exceptions.
>> javac could not find/access
>> and com.sun.javafx.stage.StageHelper classes.
>> I'm using ContextMenuContent to add new menu items to webview's default
>> context menu. I can set a new ContextMenu for Webviews but, I want to 
>> use
>> actions of default menuitems as well. Code
>> <> 
>> I'm doing something when application focus-out, but when an JavaFX 
>> Alert is
>> shown, it acts as focus-out, to avoid this circumstances I'm using
>> StageHelper Code
>> <> 
>> How can I these needs with Jigsaw builds?
>> Thanks.

More information about the openjfx-dev mailing list