summaryrefslogtreecommitdiff
authorDan Zhang <danielzhang@google.com>2019-12-10 03:51:56 (GMT)
committer Android Partner Code Review <android-gerrit-partner@google.com>2019-12-10 03:51:56 (GMT)
commit845a41823b5b868990b94207c1bd0baa122ff8eb (patch)
tree8cfab15b6105e1b9c4be33856de841a1d1f2259a
parentf244b40bd60c804f64ef7904974e88526bcc5ba2 (diff)
parent74e784c5759dc1ebd750e8be9c33ada9f221cec3 (diff)
downloadcommon-845a41823b5b868990b94207c1bd0baa122ff8eb.zip
common-845a41823b5b868990b94207c1bd0baa122ff8eb.tar.gz
common-845a41823b5b868990b94207c1bd0baa122ff8eb.tar.bz2
Merge "GlobalKey: process google function keys [2/2]" into q-tv-dev
Diffstat
-rwxr-xr-xatv_gms_overlay/frameworks/base/core/res/res/xml/global_keys.xml30
-rwxr-xr-xcore_amlogic.mk4
2 files changed, 34 insertions, 0 deletions
diff --git a/atv_gms_overlay/frameworks/base/core/res/res/xml/global_keys.xml b/atv_gms_overlay/frameworks/base/core/res/res/xml/global_keys.xml
new file mode 100755
index 0000000..d0c8033
--- a/dev/null
+++ b/atv_gms_overlay/frameworks/base/core/res/res/xml/global_keys.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, The Android Open Source 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.
+*/
+-->
+<global_keys version="1">
+ <!-- Example format: id = keycode to handle globally. component = component which will handle
+ this key. -->
+ <key keyCode="KEYCODE_F1" component="com.droidlogic/.GlobalKeyReceiver" />
+ <key keyCode="KEYCODE_F2" component="com.droidlogic/.GlobalKeyReceiver" />
+ <key keyCode="KEYCODE_SETTINGS" component="com.droidlogic/.GlobalKeyReceiver" />
+ <key keyCode="KEYCODE_DVR" component="com.google.android.tv/.receiver.GlobalKeyReceiver" />
+ <key keyCode="KEYCODE_GUIDE" component="com.google.android.tv/.receiver.GlobalKeyReceiver" />
+ <key keyCode="KEYCODE_TV" component="com.google.android.tv/.receiver.GlobalKeyReceiver" />
+ <key keyCode="KEYCODE_TV_INPUT" component="com.google.android.tv/.receiver.GlobalKeyReceiver" />
+ <!-- OEMs might want to add more custom global key handlings for TV specific key codes. -->
+</global_keys> \ No newline at end of file
diff --git a/core_amlogic.mk b/core_amlogic.mk
index d2212ec..5c98703 100755
--- a/core_amlogic.mk
+++ b/core_amlogic.mk
@@ -459,3 +459,7 @@ endif
PRODUCT_COPY_FILES += \
frameworks/native/data/etc/android.software.midi.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.midi.xml
+
+ifeq ($(TARGET_BUILD_GOOGLE_ATV), true)
+PRODUCT_PACKAGE_OVERLAYS += device/amlogic/common/atv_gms_overlay
+endif