<Swing Dev> Code review request: 8026929: remove accelerators from policytool resources

Alexander Potochkin alexander.potochkin at oracle.com
Mon Oct 28 16:56:13 UTC 2013


Hello Leif

Okay, I approve

Thanks
alexp

On 10/22/2013 8:12 PM, Leif Samuelsson wrote:
> Hi Alexander,
>
> On 2013-10-22 04:25, Alexander Potochkin wrote:
>> Hello Leif
>>
>> There was a special logic for keyStrokes on MacOS 
>> inPolicyTool.addMenuItem(),
>> could you make sure that the new code correctly set keyStrokes on MacOS?
>
> That logic is still there, but it was simplified. As long as the 
> accelerator
> string is defined with a single character, it will be set with the 
> platform
> specific shortcut modifier "control" or "meta". If the string is 
> longer, it
> will be passed to KeyStroke.getKeyStroke(String) for parsing.
>
> Thanks,
> Leif
>
>> Thanks
>> alexp
>>> Hi All,
>>>
>>> This is a small additional fix to PolicyTool to move the default
>>> accelerators for File->New/Open/Save from the resource bundle to
>>> hard coded values in PolicyTool.java.
>>>
>>> This is done to avoid confusing the translators about the difference
>>> between mnemonics and accelerators. Accelerators are typically not
>>> localized, but this fix will still allow overriding the values for
>>> rare cases, by specifying them in a localized resource bundle.
>>>
>>>   http://cr.openjdk.java.net/~weijun/8026929/webrev.00/
>>>
>>> I am the Contributor for this bug fix, and Max (Weijun) will be the
>>> Committer.
>>>
>>> Thanks,
>>> Leif
>>




More information about the swing-dev mailing list