[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-openjfx-dev
Subject:    Re: Accelerators - odd behavior
From:       Kevin Rushforth <kevin.rushforth () oracle ! com>
Date:       2014-09-27 15:19:53
Message-ID: 5426D599.7030905 () oracle ! com
[Download RAW message or body]

Thanks.

-- Kevin


Tomas Mikula wrote:
> On Sat, Sep 27, 2014 at 12:02 AM, Kevin Rushforth
> <kevin.rushforth@oracle.com> wrote:
>   
>> Can you add this information to the JIRA?
>>
>> https://javafx-jira.kenai.com/browse/RT-38830
>>     
>
> I added it to https://javafx-jira.kenai.com/browse/RT-27602.
>
> Tomas
>
>   
>> Thanks.
>>
>> -- Kevin
>>
>>
>> Tomas Mikula wrote:
>>     
>>> Anyway, the algorithm used in KeyCharacterCombination looks odd to me.
>>>
>>> What it does is it tries to find a key code capable of producing the
>>> character and then compares it to the event's key code.
>>>
>>> It would make more sense to me if it took the event, converted it to a
>>> character it produced and then compare the characters.
>>>
>>> This way your first attempt to capture both MINUS and SUBTRACT with a
>>> single KeyCharacterCombination("-") would work, as well as capturing
>>> all of Shift-EQUALS, PLUS, ADD with a single
>>> KeyCharacterCombination("+").
>>>
>>> Tomas
>>>
>>> On Fri, Sep 26, 2014 at 9:11 PM, Tomas Mikula <tomas.mikula@gmail.com>
>>> wrote:
>>>
>>>       
>>>>> That doesn't explain why this isn't happening for PLUS.
>>>>>
>>>>>           
>>>> KeyCodeCombination(KeyCode.PLUS, KeyCombination.CONTROL_DOWN)
>>>>
>>>> is never matched. It might even be impossible to get a KEY_PRESSED
>>>> event with key code PLUS with English keyboard layout. When I switch
>>>> keyboard layout to Slovak, which has the '+' sign accessible without
>>>> Shift, I do get the runnable fired twice.
>>>>
>>>> Best,
>>>> Tomas
>>>>
>>>>         
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic