Remove __linux__ ifdefs where not needed
The downstream branches now know about Parcel and binder, so in some
places, these #ifdef statements are not needed.
This CL should help reduce the divergence with downstream efforts. See
the merge conflict resolution CL as an example:
https://googleplex-android-review.git.corp.google.com/c/platform/frameworks/native/+/27201796/-2..3
Bug: 309829647
Test: presubmit
Change-Id: Iec17cface5069ca79a565c205546db8ada8a07ee
diff --git a/libs/input/KeyCharacterMap.cpp b/libs/input/KeyCharacterMap.cpp
index 41909bf..f75bf41 100644
--- a/libs/input/KeyCharacterMap.cpp
+++ b/libs/input/KeyCharacterMap.cpp
@@ -19,11 +19,9 @@
#include <stdlib.h>
#include <string.h>
-#ifdef __linux__
-#include <binder/Parcel.h>
-#endif
#include <android/keycodes.h>
#include <attestation/HmacKeyManager.h>
+#include <binder/Parcel.h>
#include <input/InputEventLabels.h>
#include <input/KeyCharacterMap.h>
#include <input/Keyboard.h>
@@ -611,7 +609,6 @@
}
}
-#ifdef __linux__
std::unique_ptr<KeyCharacterMap> KeyCharacterMap::readFromParcel(Parcel* parcel) {
if (parcel == nullptr) {
ALOGE("%s: Null parcel", __func__);
@@ -744,7 +741,6 @@
parcel->writeInt32(toAndroidKeyCode);
}
}
-#endif // __linux__
// --- KeyCharacterMap::Parser ---