summaryrefslogtreecommitdiff
path: root/libs/input/KeyCharacterMap.cpp
diff options
context:
space:
mode:
author Brett Chabot <brettchabot@google.com> 2020-11-04 17:39:36 -0800
committer Brett Chabot <brettchabot@google.com> 2020-11-04 18:56:42 -0800
commitfaa986c076dffff0be41dd866462494a76d0ad90 (patch)
tree767586452e7f9b522df5f4f00ad48e54c342afbd /libs/input/KeyCharacterMap.cpp
parenta267bd3745798d20270dff422bafc73a64d227ae (diff)
Fix libinput mac build, hopefully.
Restore the ifdefs removed in go/ag/12549959, but using ifdef __linux__ instead of __ANDROID__. Test: m libinput Bug: 172023026 Change-Id: Iafbf592e7b937b780e5ffc2df490a6c17f5f6cf5
Diffstat (limited to 'libs/input/KeyCharacterMap.cpp')
-rw-r--r--libs/input/KeyCharacterMap.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/libs/input/KeyCharacterMap.cpp b/libs/input/KeyCharacterMap.cpp
index 2623ecde45..d5457eaf08 100644
--- a/libs/input/KeyCharacterMap.cpp
+++ b/libs/input/KeyCharacterMap.cpp
@@ -19,7 +19,9 @@
#include <stdlib.h>
#include <string.h>
+#ifdef __linux__
#include <binder/Parcel.h>
+#endif
#include <android/keycodes.h>
#include <attestation/HmacKeyManager.h>
#include <input/InputEventLabels.h>
@@ -587,6 +589,7 @@ void KeyCharacterMap::addLockedMetaKey(Vector<KeyEvent>& outEvents,
}
}
+#ifdef __linux__
std::shared_ptr<KeyCharacterMap> KeyCharacterMap::readFromParcel(Parcel* parcel) {
if (parcel == nullptr) {
ALOGE("%s: Null parcel", __func__);
@@ -672,7 +675,7 @@ void KeyCharacterMap::writeToParcel(Parcel* parcel) const {
parcel->writeInt32(0);
}
}
-
+#endif // __linux__
// --- KeyCharacterMap::Key ---