OP6: Keylayout to support dt2w

This commit is contained in:
Pierre-Hugues Husson 2018-09-10 00:32:11 +02:00
parent e064c6f310
commit 3f1fb0d20b
3 changed files with 38 additions and 1 deletions

View File

@ -78,6 +78,7 @@ PRODUCT_PACKAGES += \
endif
PRODUCT_PACKAGES += \
android.hardware.wifi.hostapd-V1.0-java \
vendor.huawei.hardware.biometrics.fingerprint-V2.1-java \
vendor.huawei.hardware.tp-V1.0-java \
vendor.qti.hardware.radio.am-V1.0-java \
@ -88,4 +89,6 @@ PRODUCT_COPY_FILES += \
PRODUCT_COPY_FILES += \
device/phh/treble/files/samsung-gpio_keys.kl:system/phh/samsung-gpio_keys.kl \
device/phh/treble/files/samsung-sec_touchscreen.kl:system/phh/samsung-sec_touchscreen.kl
device/phh/treble/files/samsung-sec_touchscreen.kl:system/phh/samsung-sec_touchscreen.kl \
device/phh/treble/files/oneplus6-synaptics_s3320.kl:system/phh/oneplus6-synaptics_s3320.kl \

View File

@ -0,0 +1,28 @@
# Copyright (c) 2015, The Linux Foundation. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above
# copyright notice, this list of conditions and the following
# disclaimer in the documentation and/or other materials provided
# with the distribution.
# * Neither the name of The Linux Foundation nor the names of its
# contributors may be used to endorse or promote products derived
# from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
# BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
# OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
key 62 WAKEUP

View File

@ -60,6 +60,12 @@ changeKeylayout() {
changed=true
fi
if [ "$(getprop ro.vendor.product.device)" == "OnePlus6" ];then
cp /system/phh/oneplus6-synaptics_s3320.kl /mnt/phh/keylayout/synaptics_s3320.kl
chmod 0644 /mnt/phh/keylayout/synaptics_s3320.kl
changed=true
fi
if [ "$changed" == true ];then
mount -o bind /mnt/phh/keylayout /system/usr/keylayout
restorecon -R /system/usr/keylayout