Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 44366c4a authored by Vaibhav Devmurari's avatar Vaibhav Devmurari
Browse files

Add KeyGlyphMap providers from AOSP

Test: None
Bug: 345440920
Flag: com.android.hardware.input.keyboard_glyph_map
Change-Id: I98250c2863a8c5d4b9278b84dd104e02e04f67b3
parent 2e891dd2
Loading
Loading
Loading
Loading
+18 −0
Original line number Diff line number Diff line
@@ -19,5 +19,23 @@
            <meta-data android:name="android.hardware.input.metadata.KEYBOARD_LAYOUTS"
                    android:resource="@xml/keyboard_layouts" />
        </receiver>

        <receiver android:name=".KeyGlyphMapProvider"
                  android:exported="true">
            <intent-filter>
                <action android:name="android.hardware.input.action.QUERY_KEYBOARD_GLYPH_MAPS" />
            </intent-filter>
            <meta-data android:name="android.hardware.input.metadata.KEYBOARD_GLYPH_MAPS"
                       android:resource="@xml/keyboard_glyph_maps" />
        </receiver>

        <receiver android:name=".OverlayKeyGlyphMapProvider"
                  android:exported="true">
            <intent-filter>
                <action android:name="android.hardware.input.action.QUERY_KEYBOARD_GLYPH_MAPS" />
            </intent-filter>
            <meta-data android:name="android.hardware.input.metadata.KEYBOARD_GLYPH_MAPS"
                       android:resource="@xml/keyboard_glyph_maps_overlay" />
        </receiver>
    </application>
</manifest>
+22 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright 2024 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.
  -->
<keyboard-glyph-maps xmlns:android="http://schemas.android.com/apk/res/android">
<!--    <key-glyph-map-->
<!--        android:glyphMap="@xml/xyz_glyph_map"-->
<!--        android:vendorId="0x1234"-->
<!--        android:productId="0x3456" />-->
</keyboard-glyph-maps>
 No newline at end of file
+20 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright 2024 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.
  -->
<keyboard-glyph-maps xmlns:android="http://schemas.android.com/apk/res/android">
<!-- NOTE: This is reserved for glyph maps to be provided using RRO. For providing glyph maps in
     AOSP use key_glyph_maps.xml instead -->
</keyboard-glyph-maps>
 No newline at end of file
+28 −0
Original line number Diff line number Diff line
/*
 * Copyright 2024 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.
 */

package com.android.inputdevices;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;

public class KeyGlyphMapProvider extends BroadcastReceiver {
    @Override
    public void onReceive(Context context, Intent intent) {
        // Nothing to do at this time.
    }
}
+28 −0
Original line number Diff line number Diff line
/*
 * Copyright 2024 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.
 */

package com.android.inputdevices;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;

public class OverlayKeyGlyphMapProvider extends BroadcastReceiver {
    @Override
    public void onReceive(Context context, Intent intent) {
        // Nothing to do at this time.
    }
}