jQWidgets Forums

jQuery UI Widgets Forums Lists DropDownList keyboard/keypad keycode from keydown

Tagged: 

This topic contains 5 replies, has 2 voices, and was last updated by  Peter Stoev 11 years, 9 months ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
  • keyboard/keypad keycode from keydown #26345

    calimero100582
    Participant

    I checked to have the keyboard to work for my dropdownlist, and I found 2 issues:

    For the keypad the returned keycode is incorrect with the keydown event. See: http://www.w3.org/2002/09/tests/keys.html

    the keypress should be used

    Also, if I use a specific type, with a display member that point to an integer, I have an exception saying toUpperCase does not exist for Object 1

    In _getMatches, the following:

    keyboard/keypad keycode from keydown #26346

    Peter Stoev
    Keymaster

    Hi calimero100582,

    Please, do not paste code from the widget’s source in the Forum or anywhere else as this is in violation with our EULA. Regarding your suggestions about toString() – we will check that. Regarding the “keypress” – the current implementation of the widget is correct and it already takes into account whether Shift is pressed or not so the entered string is correct.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com/

    keyboard/keypad keycode from keydown #26351

    calimero100582
    Participant

    in the event keydown, the keycode is not good for keypad/numpad, it is correct for the number above the letters, but not on the right.

    if you check the link, you’ll see for the number above letters:

    keydown (0): [keyCode: 49][shift: false][ctrl: false][alt: false][meta: false]
    keypress (1): [keyCode: 49][charCode: 49][character: 1][shift: false][ctrl: false][alt: false][meta: false]
    keyup (2): [keyCode: 49][shift: false][ctrl: false][alt: false][meta: false]
    

    and for the numpad:

    keydown (3): [keyCode: 97][shift: false][ctrl: false][alt: false][meta: false]
    keypress (4): [keyCode: 49][charCode: 49][character: 1][shift: false][ctrl: false][alt: false][meta: false]
    keyup (5): [keyCode: 97][shift: false][ctrl: false][alt: false][meta: false]
    

    you’ll see the keyCode in keydown and keypress are different if we use the numpad

    keyboard/keypad keycode from keydown #26375

    Peter Stoev
    Keymaster

    Hi calimero100582,

    We will continue with our implementation and do not find necessary to change the event handling of the incremental search feature. Also note that ‘KeyPress’ is an event which is not fired for all keys in all browsers and in general is not a cross browser compatible JavaScript event.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com/

    keyboard/keypad keycode from keydown #26429

    calimero100582
    Participant

    ok,

    As there is too much things I can’t work with, I’ll remove DropDownList then and use another tool

    I have this fiddle to check back later if you change anything

    thanks

    keyboard/keypad keycode from keydown #26431

    Peter Stoev
    Keymaster

    Hi calimero100582,

    Thanks for the sample.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com/

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.