Answer the question
In order to leave comments, you need to log in
What are the event types rawKeyDown, char?
Hello. I haven't done extension development before, but it became necessary to implement user input imitation, which led me to extensions. The question is the following:
When triggering keyboard events (Input.dispatchKeyEvent), there are 4 types of event keyDown, keyUp, rawKeyDown, char. The first two types of events are clear, but about the rest I can not find anything absolutely and nowhere. Other than this page https://chromium.googlesource.com/chromium/blink/+...
Here is the most important part :
switch (type) {
case PlatformEvent::KeyUp:
return EventTypeNames::keyup;
case PlatformEvent::RawKeyDown:
return EventTypeNames::keydown;
case PlatformEvent::Char:
return EventTypeNames::keypress;
case PlatformEvent::KeyDown:
// The caller should disambiguate the combined event into RawKeyDown or Char events.
break;
default:
break;
}
Answer the question
In order to leave comments, you need to log in
The correct answer is to read the source codes of Google. chrome, if you really want to find some kind of flaw.
What you are asking about is a cross-platform wrapper over the event models of various operating systems, which is why it is called PlatformEvent. raw I suppose the event of pressing a non-character key, such as cmd / ctrl / enter, etc.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question