Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KeyboardEvent doesn't bring actual character input #15233

Closed
DartBot opened this issue Nov 21, 2013 · 6 comments
Closed

KeyboardEvent doesn't bring actual character input #15233

DartBot opened this issue Nov 21, 2013 · 6 comments
Labels
area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. closed-duplicate Closed in favor of an existing report library-html

Comments

@DartBot
Copy link

DartBot commented Nov 21, 2013

This issue was originally filed by li....@intel.com


What steps will reproduce the problem?
1.
2.
3.

What is the expected output? What do you see instead?
Create a keyboard event, and dispatch it to specified DOM node, it works fine, the dom node can receive the keyboard event, but it doesn't bring actual char input, which is different from actual keyboard event.

What version of the product are you using? On what operating system?
I am using trunk building, chromium M33

Please provide any additional information below.
Sample Code:
<input type="text" id="name">
var name = document.getElementById("name");
name.onkeydown = function(event) {
  var keyEvent = document.createEvent("KeyboardEvents");
  keyEvent.initKeyboardEvent("keydown", event.bubbles, event.cancelable, event.view,
      event.keyIdentifier, event.location, event.ctrlKey, event.altKey,
      event.shiftKey, event.metaKey, event.altGraphKey);
  name.dispatchEvent(keyEvent);
  name.onkeydown = null;
}

If I input "a" char to the input node, I think "aa" should be displayed, since both real and virtual keyboard event are dispatched, but I just saw "a" in the input node.

@DartBot
Copy link
Author

DartBot commented Nov 21, 2013

This comment was originally written by li....@intel.com


I don't know whether the difference of actual and simulated keyboard event was discussed or not.

@iposva-google
Copy link
Contributor

Added Area-Dart2JS, Triaged labels.

@kasperl
Copy link

kasperl commented Nov 22, 2013

Removed Area-Dart2JS label.
Added Area-HTML label.

@blois
Copy link
Contributor

blois commented Nov 22, 2013

cc @efortuna.

@kevmoo
Copy link
Member

kevmoo commented Apr 7, 2014

Removed Area-HTML label.
Added Area-Library, Library-Html labels.

@efortuna
Copy link
Contributor

Added Duplicate label.
Marked as being merged into #13902.

@DartBot DartBot added Type-Defect area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. library-html closed-duplicate Closed in favor of an existing report labels May 14, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-core-library SDK core library issues (core, async, ...); use area-vm or area-web for platform specific libraries. closed-duplicate Closed in favor of an existing report library-html
Projects
None yet
Development

No branches or pull requests

6 participants