From 531bc8dce321713c69e79272c75bfbb01798146b Mon Sep 17 00:00:00 2001 From: Danny Wood Date: Thu, 25 Apr 2019 16:46:36 +0100 Subject: [PATCH] a5xelte: Add device hardware key layout Change-Id: I40dd4b4eda728ff64337811a91843bf622b9e81b --- device.mk | 7 ++++++- keylayout/gpio_keys.kl | 25 +++++++++++++++++++++++++ keylayout/sec_touchkey.kl | 19 +++++++++++++++++++ 3 files changed, 50 insertions(+), 1 deletion(-) create mode 100644 keylayout/gpio_keys.kl create mode 100644 keylayout/sec_touchkey.kl diff --git a/device.mk b/device.mk index 1088a75..5b5cbbd 100644 --- a/device.mk +++ b/device.mk @@ -40,7 +40,7 @@ PRODUCT_COPY_FILES += \ PRODUCT_PACKAGES += \ android.hardware.bluetooth@1.0-service - + # GPS PRODUCT_COPY_FILES += \ $(LOCAL_PATH)/configs/gps/gps.conf:system/etc/gps.conf \ @@ -50,6 +50,11 @@ PRODUCT_COPY_FILES += \ PRODUCT_COPY_FILES += \ $(LOCAL_PATH)/manifest.xml:$(TARGET_COPY_OUT_VENDOR)/manifest.xml +# Keylayouts +PRODUCT_COPY_FILES += \ + $(LOCAL_PATH)/keylayout/gpio_keys.kl:system/usr/keylayout/gpio_keys.kl \ + $(LOCAL_PATH)/keylayout/sec_touchkey.kl:system/usr/keylayout/sec_touchkey.kl + # Permissions PRODUCT_COPY_FILES += \ frameworks/native/data/etc/android.hardware.bluetooth_le.xml:system/etc/permissions/android.hardware.bluetooth_le.xml \ diff --git a/keylayout/gpio_keys.kl b/keylayout/gpio_keys.kl new file mode 100644 index 0000000..32a9156 --- /dev/null +++ b/keylayout/gpio_keys.kl @@ -0,0 +1,25 @@ +# +# Copyright (C) 2014 The CyanogenMod Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +key 114 VOLUME_DOWN +key 115 VOLUME_UP +key 116 POWER +key 152 POWER +key 172 HOME +key 256 HEADSETHOOK +key 257 VOLUME_UP +key 258 VOLUME_DOWN + diff --git a/keylayout/sec_touchkey.kl b/keylayout/sec_touchkey.kl new file mode 100644 index 0000000..ea6a5d7 --- /dev/null +++ b/keylayout/sec_touchkey.kl @@ -0,0 +1,19 @@ +# +# Copyright (C) 2016 The CyanogenMod Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +key 158 BACK VIRTUAL +key 254 APP_SWITCH VIRTUAL + -- 2.20.1