<AWT Dev> RFR: JDK-8165232 XKeycodeToKeysym is deprecated and should be replaced with XkbKeycodeToKeysym
Alan Burlison
Alan.Burlison at oracle.com
Tue Sep 6 20:14:07 UTC 2016
On 06/09/2016 20:29, Phil Race wrote:
> You are removing this : native method
>
> Java_sun_awt_X11_XlibWrapper_XKeycodeToKeysym There is no explanation
> about this .. and unless you discovered this method is obsolete (never
> called) it seems like it should also be updated .. not deleted. And
> since I see it called from XToolkit.java it appears updating is what is
> needed. You would then also need to revert the mapfile change.
Hmm, yes - good point... If
Java_sun_awt_X11_XlibWrapper_XKeycodeToKeysym is only ever used within
the AWT code then it could be replaced by calling
Java_sun_awt_X11_XlibWrapper_XkbKeycodeToKeysym (which already exists).
However if it is ever used outside then it's more of a problem. I wasn't
sure if XlibWrapper.c was internal-only or not. If it isn't then I think
the only option is to leave the
Java_sun_awt_X11_XlibWrapper_XKeycodeToKeysym function in place and just
change the implementation to use XkbKeycodeToKeysym underneath. If so,
should Java_sun_awt_X11_XlibWrapper_XKeycodeToKeysym be flagged as
deprecated?
In either case, I believe the existing Java calls to
Java_sun_awt_X11_XlibWrapper_XKeycodeToKeysym need to be switched over
to Java_sun_awt_X11_XlibWrapper_XkbKeycodeToKeysym. I thought I'd found
those, clearly not.
Thanks for the catch,
--
Alan Burlison
--
More information about the awt-dev
mailing list