Add Redmagic 5G DT2Z KL

This commit is contained in:
Pierre-Hugues Husson 2020-06-20 20:11:04 +02:00
parent 46c5eb1273
commit 97b340689d
3 changed files with 9 additions and 1 deletions

View File

@ -120,7 +120,8 @@ PRODUCT_COPY_FILES += \
device/phh/treble/files/moto-uinput-egis.kl:system/phh/moto-uinput-egis.kl \
device/phh/treble/files/daisy-buttonJack.kl:system/phh/daisy-buttonJack.kl \
device/phh/treble/files/daisy-uinput-fpc.kl:system/phh/daisy-uinput-fpc.kl \
device/phh/treble/files/daisy-uinput-goodix.kl:system/phh/daisy-uinput-goodix.kl
device/phh/treble/files/daisy-uinput-goodix.kl:system/phh/daisy-uinput-goodix.kl \
device/phh/treble/files/nubia-nubia_synaptics_dsx.kl:system/phh/nubia-nubia_synaptics_dsx.kl
SELINUX_IGNORE_NEVERALLOWS := true

View File

@ -0,0 +1 @@
key 0x44 POWER

View File

@ -170,6 +170,12 @@ changeKeylayout() {
changed=true
fi
if getprop ro.vendor.build.fingerprint |grep -q -e nubia/NX659;then
cp /system/phh/nubia-nubia_synaptics_dsx.kl /mnt/phh/keylayout/nubia_synaptics_dsx.kl
chmod 0644 /mnt/phh/keylayout/nubia_synaptics_dsx.kl
changed=true
fi
if [ "$changed" = true ]; then
mount -o bind /mnt/phh/keylayout /system/usr/keylayout
restorecon -R /system/usr/keylayout