Calcudoku puzzle forum
https://www.calcudoku.org/forum/

small fixes
https://www.calcudoku.org/forum/viewtopic.php?f=18&t=308
Page 3 of 3

Author:  pnm  [ Fri Aug 31, 2012 10:55 am ]
Post subject:  Re: small fixes

mparisi wrote:
I think you've introduced another bug, however. The "-" key doesn't seem to work any more for entering negative numbers.

Different keyboards produce different "key codes" for keys like '-', '=' etc.

I'll send you e-mail with a link to a test page where you can see which code your '-' key produces
(I can then add it to the list of codes for the '-' key..)

Patrick

Author:  pnm  [ Fri Aug 31, 2012 5:17 pm ]
Post subject:  Re: small fixes

pnm wrote:
Different keyboards produce different "key codes" for keys like '-', '=' etc.

In this case, it turns out different browsers produce different keycodes
for the same key :-(

See for example:
http://www.javascripter.net/faq/keycodes.htm

About halfway down the page it lists 109 as the keycode for "-" in Firefox and Opera,
and 189 as the keycode for the same key in IE, Safari, and Chrome.

Both these codes are caught by my software. Now it seems the keycode for "-" has
changed to 173 for Firefox (?!) (also on my keyboard (!)).

In any case, I added 173, so the regular "-" key should work again now...

Patrick


Edit: other people have run into the same problem:
https://github.com/openlayers/openlayers/issues/605

Not sure yet if the change was intentional.

Page 3 of 3 All times are UTC + 1 hour [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/