Home
last modified time | relevance | path

Searched refs:scanCode (Results 1 – 25 of 45) sorted by relevance

12

/frameworks/native/services/inputflinger/reader/mapper/
DKeyboardInputMapper.cpp212 int32_t scanCode = rawEvent->code; in process() local
216 if (isKeyboardOrGamepadKey(scanCode)) { in process()
217 processKey(rawEvent->when, rawEvent->value != 0, scanCode, usageCode); in process()
235 bool KeyboardInputMapper::isKeyboardOrGamepadKey(int32_t scanCode) { in isKeyboardOrGamepadKey() argument
236 return scanCode < BTN_MOUSE || scanCode >= BTN_WHEEL || in isKeyboardOrGamepadKey()
237 (scanCode >= BTN_MISC && scanCode < BTN_MOUSE) || in isKeyboardOrGamepadKey()
238 (scanCode >= BTN_JOYSTICK && scanCode < BTN_DIGI); in isKeyboardOrGamepadKey()
270 void KeyboardInputMapper::processKey(nsecs_t when, bool down, int32_t scanCode, int32_t usageCode) { in processKey() argument
275 if (getDeviceContext().mapKey(scanCode, usageCode, mMetaState, &keyCode, &keyMetaState, in processKey()
289 ssize_t keyDownIndex = findKeyDown(scanCode); in processKey()
[all …]
DKeyboardInputMapper.h38 virtual int32_t getScanCodeState(uint32_t sourceMask, int32_t scanCode) override;
52 int32_t scanCode; member
85 bool isKeyboardOrGamepadKey(int32_t scanCode);
88 void processKey(nsecs_t when, bool down, int32_t scanCode, int32_t usageCode);
92 ssize_t findKeyDown(int32_t scanCode);
DCursorInputMapper.cpp450 int32_t CursorInputMapper::getScanCodeState(uint32_t sourceMask, int32_t scanCode) { in getScanCodeState() argument
451 if (scanCode >= BTN_MOUSE && scanCode < BTN_JOYSTICK) { in getScanCodeState()
452 return getDeviceContext().getScanCodeState(scanCode); in getScanCodeState()
DCursorInputMapper.h67 virtual int32_t getScanCodeState(uint32_t sourceMask, int32_t scanCode) override;
/frameworks/native/libs/input/
DKeyLayoutMap.cpp85 status_t KeyLayoutMap::mapKey(int32_t scanCode, int32_t usageCode, in mapKey() argument
87 const Key* key = getKey(scanCode, usageCode); in mapKey()
90 ALOGD("mapKey: scanCode=%d, usageCode=0x%08x ~ Failed.", scanCode, usageCode); in mapKey()
102 scanCode, usageCode, *outKeyCode, *outFlags); in mapKey()
107 const KeyLayoutMap::Key* KeyLayoutMap::getKey(int32_t scanCode, int32_t usageCode) const { in getKey() argument
114 if (scanCode) { in getKey()
115 ssize_t index = mKeysByScanCode.indexOfKey(scanCode); in getKey()
134 status_t KeyLayoutMap::mapAxis(int32_t scanCode, AxisInfo* outAxisInfo) const { in mapAxis() argument
135 ssize_t index = mAxes.indexOfKey(scanCode); in mapAxis()
138 ALOGD("mapAxis: scanCode=%d ~ Failed.", scanCode); in mapAxis()
[all …]
DVirtualKeyMap.cpp99 bool success = parseNextIntField(&defn.scanCode) in parse()
113 defn.scanCode, defn.centerX, defn.centerY, defn.width, defn.height); in parse()
/frameworks/native/services/inputflinger/reader/include/
DInputDevice.h80 int32_t getScanCodeState(uint32_t sourceMask, int32_t scanCode);
228 inline status_t mapKey(int32_t scanCode, int32_t usageCode, int32_t metaState, in mapKey() argument
230 return mEventHub->mapKey(mId, scanCode, usageCode, metaState, outKeycode, outMetaState, in mapKey()
233 inline status_t mapAxis(int32_t scanCode, AxisInfo* outAxisInfo) const { in mapAxis() argument
234 return mEventHub->mapAxis(mId, scanCode, outAxisInfo); in mapAxis()
237 inline int32_t getScanCodeState(int32_t scanCode) const { in getScanCodeState() argument
238 return mEventHub->getScanCodeState(mId, scanCode); in getScanCodeState()
251 inline bool hasScanCode(int32_t scanCode) const { in hasScanCode() argument
252 return mEventHub->hasScanCode(mId, scanCode); in hasScanCode()
DEventHub.h181 virtual status_t mapKey(int32_t deviceId, int32_t scanCode, int32_t usageCode,
185 virtual status_t mapAxis(int32_t deviceId, int32_t scanCode, AxisInfo* outAxisInfo) const = 0;
209 virtual int32_t getScanCodeState(int32_t deviceId, int32_t scanCode) const = 0;
221 virtual bool hasScanCode(int32_t deviceId, int32_t scanCode) const = 0;
278 virtual status_t mapKey(int32_t deviceId, int32_t scanCode, int32_t usageCode,
282 virtual status_t mapAxis(int32_t deviceId, int32_t scanCode,
287 virtual int32_t getScanCodeState(int32_t deviceId, int32_t scanCode) const override;
299 virtual bool hasScanCode(int32_t deviceId, int32_t scanCode) const override;
DInputReader.h68 int32_t scanCode) override;
105 virtual bool shouldDropVirtualKey(nsecs_t now, int32_t keyCode, int32_t scanCode) override;
183 bool shouldDropVirtualKeyLocked(nsecs_t now, int32_t keyCode, int32_t scanCode);
DInputReaderContext.h46 virtual bool shouldDropVirtualKey(nsecs_t now, int32_t keyCode, int32_t scanCode) = 0;
/frameworks/native/include/input/
DKeyLayoutMap.h67 status_t mapKey(int32_t scanCode, int32_t usageCode,
73 status_t mapAxis(int32_t scanCode, AxisInfo* outAxisInfo) const;
97 const Key* getKey(int32_t scanCode, int32_t usageCode) const;
DVirtualKeyMap.h33 int32_t scanCode; member
DKeyCharacterMap.h130 status_t mapKey(int32_t scanCode, int32_t usageCode, int32_t* outKeyCode) const;
134 void tryRemapKey(int32_t scanCode, int32_t metaState,
/frameworks/native/services/inputflinger/
DInputListener.cpp56 int32_t keyCode, int32_t scanCode, int32_t metaState, nsecs_t downTime) in NotifyKeyArgs() argument
65 scanCode(scanCode), in NotifyKeyArgs()
78 scanCode(other.scanCode), in NotifyKeyArgs()
86 scanCode == rhs.scanCode && metaState == rhs.metaState && downTime == rhs.downTime; in operator ==()
/frameworks/native/services/inputflinger/dispatcher/
DEntry.cpp38 entry.scanCode, in verifiedKeyEventFromKeyEntry()
135 int32_t keyCode, int32_t scanCode, int32_t metaState, int32_t repeatCount, in KeyEntry() argument
144 scanCode(scanCode), in KeyEntry()
163 keyCode, scanCode, metaState, repeatCount, policyFlags); in appendDescription()
DInputState.cpp200 memento.scanCode == entry.scanCode) { in findKeyMemento()
224 memento.scanCode = entry.scanCode; in addKeyMemento()
277 memento.scanCode, memento.metaState, 0 /*repeatCount*/, in synthesizeCancelationEvents()
DEntry.h130 int32_t scanCode; member
147 uint32_t policyFlags, int32_t action, int32_t flags, int32_t keyCode, int32_t scanCode,
/frameworks/base/core/java/android/view/
DVerifiedKeyEvent.java193 int scanCode, argument
206 this.mScanCode = scanCode;
368 int scanCode = in.readInt(); in VerifiedKeyEvent() local
381 this.mScanCode = scanCode; in VerifiedKeyEvent()
/frameworks/base/core/tests/coretests/src/android/view/
DVerifiedKeyEventTest.kt48 assertEquals(SCAN_CODE, event.scanCode) in testConstructor()
160 assertEquals(event1.scanCode, event2.scanCode) in compareVerifiedKeyEvents()
/frameworks/native/services/inputflinger/reader/
DEventHub.cpp440 int32_t EventHub::getScanCodeState(int32_t deviceId, int32_t scanCode) const { in getScanCodeState()
441 if (scanCode >= 0 && scanCode <= KEY_MAX) { in getScanCodeState()
445 if (device && device->hasValidFd() && test_bit(scanCode, device->keyBitmask)) { in getScanCodeState()
449 return test_bit(scanCode, keyState) ? AKEY_STATE_DOWN : AKEY_STATE_UP; in getScanCodeState()
546 status_t EventHub::mapKey(int32_t deviceId, int32_t scanCode, int32_t usageCode, int32_t metaState, in mapKey() argument
556 if (!kcm->mapKey(scanCode, usageCode, outKeycode)) { in mapKey()
564 if (!device->keyMap.keyLayoutMap->mapKey(scanCode, usageCode, outKeycode, outFlags)) { in mapKey()
587 status_t EventHub::mapAxis(int32_t deviceId, int32_t scanCode, AxisInfo* outAxisInfo) const { in mapAxis() argument
592 status_t err = device->keyMap.keyLayoutMap->mapAxis(scanCode, outAxisInfo); in mapAxis()
607 bool EventHub::hasScanCode(int32_t deviceId, int32_t scanCode) const { in hasScanCode()
[all …]
DInputReader.cpp401 bool InputReader::shouldDropVirtualKeyLocked(nsecs_t now, int32_t keyCode, int32_t scanCode) { in shouldDropVirtualKeyLocked() argument
405 (mDisableVirtualKeysTimeout - now) * 0.000001, keyCode, scanCode); in shouldDropVirtualKeyLocked()
486 int32_t InputReader::getScanCodeState(int32_t deviceId, uint32_t sourceMask, int32_t scanCode) { in getScanCodeState() argument
489 return getStateLocked(deviceId, sourceMask, scanCode, &InputDevice::getScanCodeState); in getScanCodeState()
742 int32_t scanCode) { in shouldDropVirtualKey() argument
744 return mReader->shouldDropVirtualKeyLocked(now, keyCode, scanCode); in shouldDropVirtualKey()
/frameworks/native/libs/input/tests/
DStructLayout_test.cpp47 CHECK_OFFSET(InputMessage::Body::Key, scanCode, 72); in TestInputMessageAlignment()
121 sizeof(VerifiedKeyEvent::scanCode) + sizeof(VerifiedKeyEvent::metaState) + in TestVerifiedEventSize()
/frameworks/base/core/jni/
Dandroid_view_VerifiedKeyEvent.cpp37 event.scanCode, event.metaState, event.repeatCount); in android_view_VerifiedKeyEvent()
Dandroid_view_KeyEvent.cpp131 jint scanCode = env->GetIntField(eventObj, gKeyEventClassInfo.mScanCode); in android_view_KeyEvent_toNative() local
137 event->initialize(id, deviceId, source, displayId, *hmac, action, flags, keyCode, scanCode, in android_view_KeyEvent_toNative()
/frameworks/native/services/inputflinger/include/
DInputListener.h72 int32_t scanCode; member
80 int32_t keyCode, int32_t scanCode, int32_t metaState, nsecs_t downTime);

12