Closed Bug 1138745 Opened 9 years ago Closed 6 years ago

Capturing keydown events doesn't work anymore

Categories

(Firefox OS Graveyard :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: felix.klee, Unassigned)

Details

User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Firefox/38.0
Build ID: 20150302004030

Steps to reproduce:

Upgraded my Flame from a 2.2 version to 3.0.0.0-prerelease / 2015032010223.

Connected the phone to WebIDE in Firefox Developer Edition on my PC, started my privileged app Trigger, and ran in the console:

    window.addEventListener('keydown', function () {
        console.log('Key pressed.');
    });

Pressed the volume-up and volume-down buttons.


Actual results:

No output was added to the console when pressing a volume button.


Expected results:

"Key pressed." in the console.

Note that capturing volume button events worked in the 2.2 version that I had installed before.
Just downgraded 2.2.0.0-prerelease / 20150303002527. Here it works. When I press one of the buttons, then I get on the console: "Key pressed."
NI myself as a reminding for further investigation
Flags: needinfo?(tzhuang)
I think there is something wrong in the connection with WebIDE. Because if you put 

    window.addEventListener('keydown', function () {
        console.log('Key pressed.');
    });

in you app code instead of run it via WebIDE, it will definetly print out something in console.

Here is an quick test. Fire up your browser in Flame and go to this url
http://dwi2.com/public/tk.html
This page print out every keydown and keyup events it receives. 

I did test it myself and volume keys work fine.
Flags: needinfo?(tzhuang) → needinfo?(felix.klee)
Seems to be an issue with `console.log`. This works:

    window.addEventListener('keydown', function () {
        alert('Key pressed.');
    });
Flags: needinfo?(felix.klee)
Firefox OS is not being worked on
Status: UNCONFIRMED → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.