summaryrefslogtreecommitdiff
path: root/include/input/InputEventLabels.h
diff options
context:
space:
mode:
author Colin Cross <ccross@android.com> 2016-09-28 23:27:30 +0000
committer android-build-merger <android-build-merger@google.com> 2016-09-28 23:27:30 +0000
commitfef00db3e5615ca77f2d66e8c9c35fbf423e2b76 (patch)
treeacbd40fe29df1c917513e6231ef793a8d88bd4cd /include/input/InputEventLabels.h
parent14664fb503fe8855279b62d6c2442d189d87dd7f (diff)
parent35d869c15e79f0dedf62b55f5ce32909d721542c (diff)
Merge "Fix libinput warnings" am: a4767442e3 am: a149886878
am: 35d869c15e Change-Id: I6461ef056bf41d66d391f52cfb25a680dd61b14e
Diffstat (limited to 'include/input/InputEventLabels.h')
-rw-r--r--include/input/InputEventLabels.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/include/input/InputEventLabels.h b/include/input/InputEventLabels.h
index 0bd14ea3a1..20154eb10e 100644
--- a/include/input/InputEventLabels.h
+++ b/include/input/InputEventLabels.h
@@ -425,30 +425,30 @@ static const char* lookupLabelByValue(int value, const InputEventLabel* list) {
return NULL;
}
-static int32_t getKeyCodeByLabel(const char* label) {
+static inline int32_t getKeyCodeByLabel(const char* label) {
return int32_t(lookupValueByLabel(label, KEYCODES));
}
-static const char* getLabelByKeyCode(int32_t keyCode) {
- if (keyCode >= 0 && keyCode < size(KEYCODES)) {
+static inline const char* getLabelByKeyCode(int32_t keyCode) {
+ if (keyCode >= 0 && keyCode < static_cast<int32_t>(size(KEYCODES))) {
return KEYCODES[keyCode].literal;
}
return NULL;
}
-static uint32_t getKeyFlagByLabel(const char* label) {
+static inline uint32_t getKeyFlagByLabel(const char* label) {
return uint32_t(lookupValueByLabel(label, FLAGS));
}
-static int32_t getAxisByLabel(const char* label) {
+static inline int32_t getAxisByLabel(const char* label) {
return int32_t(lookupValueByLabel(label, AXES));
}
-static const char* getAxisLabel(int32_t axisId) {
+static inline const char* getAxisLabel(int32_t axisId) {
return lookupLabelByValue(axisId, AXES);
}
-static int32_t getLedByLabel(const char* label) {
+static inline int32_t getLedByLabel(const char* label) {
return int32_t(lookupValueByLabel(label, LEDS));
}