[7u10] Review request for 7186371: [macosx] Main menu shortcuts not displayed (7u6 regression) (original) (raw)
Sergey Bylokhov Sergey.Bylokhov at oracle.com
Wed Sep 5 03:03:48 PDT 2012
- Previous message: [8] Review request for 7153339: InternalError when drawLine with Xor and Antialiasing
- Next message: [7u10] Review request for 7186371: [macosx] Main menu shortcuts not displayed (7u6 regression)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hi Everyone, Please review the fix. This is backport from jdk8 to 7u10 When we translate calls from our swing menu components to awt peer we resets information about shortcut in the setLabel(). This happens because of ScreenMenuItem.setAccelerator() method call peers setLabel(..,..,..) directly and does not initialize ScreenMenuItem.shortcut property. But default implementation of ScreenMenuItem.setLabel() assumes that this field(shortcut) will be initialized.
This works on jdk6 because it does not reset shortcut if null or empty shortcut is provided. As a solution we can use peers methods directly in both cases.
Bug: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7186371 Webrev can be found at: http://cr.openjdk.java.net/~serb/7186371/webrev.00 jdk8 changeset: http://hg.openjdk.java.net/jdk8/awt/jdk/rev/f54660c18774
-- Best regards, Sergey.
- Previous message: [8] Review request for 7153339: InternalError when drawLine with Xor and Antialiasing
- Next message: [7u10] Review request for 7186371: [macosx] Main menu shortcuts not displayed (7u6 regression)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]