Merge "Add input device property for buttons under touchpads"
This commit is contained in:
commit
e5bb2a45e0
@ -101,6 +101,9 @@ public:
|
|||||||
inline void setVibrator(bool hasVibrator) { mHasVibrator = hasVibrator; }
|
inline void setVibrator(bool hasVibrator) { mHasVibrator = hasVibrator; }
|
||||||
inline bool hasVibrator() const { return mHasVibrator; }
|
inline bool hasVibrator() const { return mHasVibrator; }
|
||||||
|
|
||||||
|
inline void setButtonUnderPad(bool hasButton) { mHasButtonUnderPad = hasButton; }
|
||||||
|
inline bool hasButtonUnderPad() const { return mHasButtonUnderPad; }
|
||||||
|
|
||||||
inline const Vector<MotionRange>& getMotionRanges() const {
|
inline const Vector<MotionRange>& getMotionRanges() const {
|
||||||
return mMotionRanges;
|
return mMotionRanges;
|
||||||
}
|
}
|
||||||
@ -115,6 +118,7 @@ private:
|
|||||||
int32_t mKeyboardType;
|
int32_t mKeyboardType;
|
||||||
sp<KeyCharacterMap> mKeyCharacterMap;
|
sp<KeyCharacterMap> mKeyCharacterMap;
|
||||||
bool mHasVibrator;
|
bool mHasVibrator;
|
||||||
|
bool mHasButtonUnderPad;
|
||||||
|
|
||||||
Vector<MotionRange> mMotionRanges;
|
Vector<MotionRange> mMotionRanges;
|
||||||
};
|
};
|
||||||
|
@ -136,6 +136,7 @@ InputDeviceInfo::InputDeviceInfo(const InputDeviceInfo& other) :
|
|||||||
mKeyboardType(other.mKeyboardType),
|
mKeyboardType(other.mKeyboardType),
|
||||||
mKeyCharacterMap(other.mKeyCharacterMap),
|
mKeyCharacterMap(other.mKeyCharacterMap),
|
||||||
mHasVibrator(other.mHasVibrator),
|
mHasVibrator(other.mHasVibrator),
|
||||||
|
mHasButtonUnderPad(other.mHasButtonUnderPad),
|
||||||
mMotionRanges(other.mMotionRanges) {
|
mMotionRanges(other.mMotionRanges) {
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -152,6 +153,7 @@ void InputDeviceInfo::initialize(int32_t id, int32_t generation,
|
|||||||
mSources = 0;
|
mSources = 0;
|
||||||
mKeyboardType = AINPUT_KEYBOARD_TYPE_NONE;
|
mKeyboardType = AINPUT_KEYBOARD_TYPE_NONE;
|
||||||
mHasVibrator = false;
|
mHasVibrator = false;
|
||||||
|
mHasButtonUnderPad = false;
|
||||||
mMotionRanges.clear();
|
mMotionRanges.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user