diff options
Diffstat (limited to 'services/inputflinger/tests/InputReader_test.cpp')
-rw-r--r-- | services/inputflinger/tests/InputReader_test.cpp | 56 |
1 files changed, 26 insertions, 30 deletions
diff --git a/services/inputflinger/tests/InputReader_test.cpp b/services/inputflinger/tests/InputReader_test.cpp index c6eb1fd..40f51b6 100644 --- a/services/inputflinger/tests/InputReader_test.cpp +++ b/services/inputflinger/tests/InputReader_test.cpp @@ -104,17 +104,16 @@ private: if (mY > mMaxY) mY = mMaxY; } - virtual void fade(Transition transition) { + virtual void fade(Transition) { } - virtual void unfade(Transition transition) { + virtual void unfade(Transition) { } - virtual void setPresentation(Presentation presentation) { + virtual void setPresentation(Presentation) { } - virtual void setSpots(const PointerCoords* spotCoords, - const uint32_t* spotIdToIndex, BitSet32 spotIdBits) { + virtual void setSpots(const PointerCoords*, const uint32_t*, BitSet32) { } virtual void clearSpots() { @@ -196,11 +195,11 @@ private: mInputDevices = inputDevices; } - virtual sp<KeyCharacterMap> getKeyboardLayoutOverlay(const InputDeviceIdentifier& identifier) { + virtual sp<KeyCharacterMap> getKeyboardLayoutOverlay(const InputDeviceIdentifier&) { return NULL; } - virtual String8 getDeviceAlias(const InputDeviceIdentifier& identifier) { + virtual String8 getDeviceAlias(const InputDeviceIdentifier&) { return String8::empty(); } }; @@ -482,7 +481,7 @@ private: return device ? device->identifier : InputDeviceIdentifier(); } - virtual int32_t getDeviceControllerNumber(int32_t deviceId) const { + virtual int32_t getDeviceControllerNumber(int32_t) const { return 0; } @@ -515,7 +514,7 @@ private: return false; } - virtual bool hasInputProperty(int32_t deviceId, int property) const { + virtual bool hasInputProperty(int32_t, int) const { return false; } @@ -553,8 +552,7 @@ private: return NULL; } - virtual status_t mapAxis(int32_t deviceId, int32_t scanCode, - AxisInfo* outAxisInfo) const { + virtual status_t mapAxis(int32_t, int32_t, AxisInfo*) const { return NAME_NOT_FOUND; } @@ -562,7 +560,7 @@ private: mExcludedDevices = devices; } - virtual size_t getEvents(int timeoutMillis, RawEvent* buffer, size_t bufferSize) { + virtual size_t getEvents(int, RawEvent* buffer, size_t) { if (mEvents.empty()) { return 0; } @@ -680,25 +678,25 @@ private: } } - virtual sp<KeyCharacterMap> getKeyCharacterMap(int32_t deviceId) const { + virtual sp<KeyCharacterMap> getKeyCharacterMap(int32_t) const { return NULL; } - virtual bool setKeyboardLayoutOverlay(int32_t deviceId, const sp<KeyCharacterMap>& map) { + virtual bool setKeyboardLayoutOverlay(int32_t, const sp<KeyCharacterMap>&) { return false; } - virtual void vibrate(int32_t deviceId, nsecs_t duration) { + virtual void vibrate(int32_t, nsecs_t) { } - virtual void cancelVibrate(int32_t deviceId) { + virtual void cancelVibrate(int32_t) { } - virtual bool isExternal(int32_t deviceId) const { + virtual bool isExternal(int32_t) const { return false; } - virtual void dump(String8& dump) { + virtual void dump(String8&) { } virtual void monitor() { @@ -763,18 +761,17 @@ private: return mListener.get(); } - virtual void disableVirtualKeysUntil(nsecs_t time) { + virtual void disableVirtualKeysUntil(nsecs_t) { } - virtual bool shouldDropVirtualKey(nsecs_t now, - InputDevice* device, int32_t keyCode, int32_t scanCode) { + virtual bool shouldDropVirtualKey(nsecs_t, InputDevice*, int32_t, int32_t) { return false; } virtual void fadePointer() { } - virtual void requestTimeoutAtTime(nsecs_t when) { + virtual void requestTimeoutAtTime(nsecs_t) { } virtual int32_t bumpGeneration() { @@ -867,12 +864,11 @@ private: } } - virtual void configure(nsecs_t when, - const InputReaderConfiguration* config, uint32_t changes) { + virtual void configure(nsecs_t, const InputReaderConfiguration*, uint32_t) { mConfigureWasCalled = true; } - virtual void reset(nsecs_t when) { + virtual void reset(nsecs_t) { mResetWasCalled = true; } @@ -881,22 +877,22 @@ private: mProcessWasCalled = true; } - virtual int32_t getKeyCodeState(uint32_t sourceMask, int32_t keyCode) { + virtual int32_t getKeyCodeState(uint32_t, int32_t keyCode) { ssize_t index = mKeyCodeStates.indexOfKey(keyCode); return index >= 0 ? mKeyCodeStates.valueAt(index) : AKEY_STATE_UNKNOWN; } - virtual int32_t getScanCodeState(uint32_t sourceMask, int32_t scanCode) { + virtual int32_t getScanCodeState(uint32_t, int32_t scanCode) { ssize_t index = mScanCodeStates.indexOfKey(scanCode); return index >= 0 ? mScanCodeStates.valueAt(index) : AKEY_STATE_UNKNOWN; } - virtual int32_t getSwitchState(uint32_t sourceMask, int32_t switchCode) { + virtual int32_t getSwitchState(uint32_t, int32_t switchCode) { ssize_t index = mSwitchStates.indexOfKey(switchCode); return index >= 0 ? mSwitchStates.valueAt(index) : AKEY_STATE_UNKNOWN; } - virtual bool markSupportedKeyCodes(uint32_t sourceMask, size_t numCodes, + virtual bool markSupportedKeyCodes(uint32_t, size_t numCodes, const int32_t* keyCodes, uint8_t* outFlags) { bool result = false; for (size_t i = 0; i < numCodes; i++) { @@ -1536,7 +1532,7 @@ protected: }; void KeyboardInputMapperTest::testDPadKeyRotation(KeyboardInputMapper* mapper, - int32_t originalScanCode, int32_t originalKeyCode, int32_t rotatedKeyCode) { + int32_t originalScanCode, int32_t, int32_t rotatedKeyCode) { NotifyKeyArgs args; process(mapper, ARBITRARY_TIME, DEVICE_ID, EV_KEY, originalScanCode, 1); |