Closed Bug 1273571 Opened 8 years ago Closed 8 years ago

Firefox 46 | Desktop | Windows 7 | Multiple Key Codes for CTRL + 3 - JavaScript Keydown Event

Categories

(Core :: DOM: UI Events & Focus Handling, defect)

46 Branch
defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: mrpatrickbrown77, Unassigned, NeedInfo)

Details

(Whiteboard: btpp-followup-2016-07-05)

User Agent: Mozilla/5.0 (iPhone; CPU iPhone OS 9_3_2 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Version/9.0 Mobile/13F69 Safari/601.1

Steps to reproduce:

- Create a number input in HTML5.

<input id="num" type="number" />

- Attach a keydown event using:

document.getElementById('num').onkeydown = function (e) { console.log(e.keyCode);  }:

- Click into the box and hit CTRL + 3 (UK keyboard).


Actual results:

- Several key codes are output for the £ symbol (instead of 1)
- CTRL is output correctly
- 3 on its own is correct as well


Expected results:

- One should be present for CTRL + 3 (£)
Summary: Firefox 46 | Desktop | Windows 7 | Multiple Key Codes - JavaScript Keydown Event → Firefox 46 | Desktop | Windows 7 | Multiple Key Codes for CTRL + 3 - JavaScript Keydown Event
Component: Untriaged → Event Handling
Product: Firefox → Core
smaug knows about this sort of thing.
Flags: needinfo?(bugs)
Whiteboard: btpp-followup-2016-07-05
Sorry, I'm missing to see what the issue here is.
I'd expect to get keydown for ctrl and then keydown for 3, and
that is what I see in Nightly on linux, and also Chrome on linux.

Is this perhaps Windows only issue? I guess I should trý, but don't have Win running atm.
Flags: needinfo?(bugs)
> Is this perhaps Windows only issue?

Could be because only on Windows, we don't compute keyCode value by ourselves, we just expose native virtual keycode value except VK_OEM_*.  However, if this is problem, I guess IE/Edge and Chrome also have same issue... I'll check it later.
Flags: needinfo?(masayuki)
I don't see any odd behavior Nightly on both Win10 and Win7. The keycode for '3' key is always 51.
(I tested on https://dvcs.w3.org/hg/d4e/raw-file/tip/key-event-test.html)

Reporter, please explain what's the problem and what should be with more details.
Flags: needinfo?(masayuki) → needinfo?(mrpatrickbrown77)
It turns out this had something to do with a site called BrowserStack.

It is meant to emulate browsers 100% but had this issue on FireFox.

I have checked normal FireFox and everything works great.

I am shutting this issue.

Thanks for looking all.
Status: UNCONFIRMED → RESOLVED
Closed: 8 years ago
Resolution: --- → INVALID
Component: Event Handling → User events and focus handling
You need to log in before you can comment on or make changes to this bug.