haydn: add RROs for setting correct device name and hotspot ssid

Check device variant by using ro.boot.hwc and
ro.boot.proudct.hardware.sku and set the correct model based on
value of ro.product.marketname on stock ROM

Change-Id: Iae15a7d3558f3c4608546e42ed655a76a0fe8868
This commit is contained in:
AdarshGrewal 2021-06-09 14:09:31 +05:30 committed by AdarshGrewal
parent 00a896bb29
commit e3d412ce73
25 changed files with 247 additions and 0 deletions

View file

@ -25,6 +25,17 @@ PRODUCT_COPY_FILES += \
DEVICE_PACKAGE_OVERLAYS += \
$(LOCAL_PATH)/overlay
# Overlays-RRO
PRODUCT_PACKAGES += \
HaydnCNSettingsProviderOverlay \
HaydnCNWifiOverlay \
HaydnGLSettingsProviderOverlay \
HaydnGLWifiOverlay \
HaydnINSettingsProviderOverlay \
HaydnINWifiOverlay \
HaydnproCNSettingsProviderOverlay \
HaydnproCNWifiOverlay
# Soong namespaces
PRODUCT_SOONG_NAMESPACES += \
$(LOCAL_PATH)

View file

@ -0,0 +1,4 @@
runtime_resource_overlay {
name: "HaydnCNSettingsProviderOverlay",
vendor: true
}

View file

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.settingsproviders.haydncn">
<overlay
android:isStatic="true"
android:priority="850"
android:requiredSystemPropertyName="ro.boot.hwc"
android:requiredSystemPropertyValue="CN"
android:targetPackage="com.android.providers.settings" />
</manifest>

View file

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- Default for Settings.Global.DEVICE_NAME $1=MODEL-->
<string name="def_device_name_simple">Redmi K40 Pro</string>
</resources>

View file

@ -0,0 +1,4 @@
runtime_resource_overlay {
name: "HaydnCNWifiOverlay",
vendor: true
}

View file

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.wifi.resources.haydncn"
android:versionCode="1"
android:versionName="1.0">
<application android:hasCode="false" />
<overlay
android:targetPackage="com.android.wifi.resources"
android:targetName="WifiCustomization"
android:isStatic="true"
android:requiredSystemPropertyName="ro.boot.hwc"
android:requiredSystemPropertyValue="CN"
android:priority="850"/>
</manifest>

View file

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<!-- Do not translate. Default access point SSID used for tethering -->
<string name="wifi_tether_configure_ssid_default" translatable="false">Redmi K40 Pro</string>
</resources>

View file

@ -0,0 +1,4 @@
runtime_resource_overlay {
name: "HaydnGLSettingsProviderOverlay",
vendor: true
}

View file

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.settingsproviders.haydngl">
<overlay
android:isStatic="true"
android:priority="850"
android:requiredSystemPropertyName="ro.boot.hwc"
android:requiredSystemPropertyValue="GL"
android:targetPackage="com.android.providers.settings" />
</manifest>

View file

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- Default for Settings.Global.DEVICE_NAME $1=MODEL-->
<string name="def_device_name_simple">Mi 11i</string>
</resources>

View file

@ -0,0 +1,4 @@
runtime_resource_overlay {
name: "HaydnGLWifiOverlay",
vendor: true
}

View file

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.wifi.resources.haydngl"
android:versionCode="1"
android:versionName="1.0">
<application android:hasCode="false" />
<overlay
android:targetPackage="com.android.wifi.resources"
android:targetName="WifiCustomization"
android:isStatic="true"
android:requiredSystemPropertyName="ro.boot.hwc"
android:requiredSystemPropertyValue="GL"
android:priority="850"/>
</manifest>

View file

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<!-- Do not translate. Default access point SSID used for tethering -->
<string name="wifi_tether_configure_ssid_default" translatable="false">Mi 11i</string>
</resources>

View file

@ -0,0 +1,4 @@
runtime_resource_overlay {
name: "HaydnINSettingsProviderOverlay",
vendor: true
}

View file

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.settingsproviders.haydnin">
<overlay
android:isStatic="true"
android:priority="850"
android:requiredSystemPropertyName="ro.boot.hwc"
android:requiredSystemPropertyValue="IN"
android:targetPackage="com.android.providers.settings" />
</manifest>

View file

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- Default for Settings.Global.DEVICE_NAME $1=MODEL-->
<string name="def_device_name_simple">Mi 11X Pro</string>
</resources>

View file

@ -0,0 +1,4 @@
runtime_resource_overlay {
name: "HaydnINWifiOverlay",
vendor: true
}

View file

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.wifi.resources.haydnin"
android:versionCode="1"
android:versionName="1.0">
<application android:hasCode="false" />
<overlay
android:targetPackage="com.android.wifi.resources"
android:targetName="WifiCustomization"
android:isStatic="true"
android:requiredSystemPropertyName="ro.boot.hwc"
android:requiredSystemPropertyValue="IN"
android:priority="850"/>
</manifest>

View file

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<!-- Do not translate. Default access point SSID used for tethering -->
<string name="wifi_tether_configure_ssid_default" translatable="false">Mi 11X Pro</string>
</resources>

View file

@ -0,0 +1,4 @@
runtime_resource_overlay {
name: "HaydnproCNSettingsProviderOverlay",
vendor: true
}

View file

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.settingsproviders.haydnprocn">
<overlay
android:isStatic="true"
android:priority="851"
android:requiredSystemPropertyName="ro.boot.hwc,ro.boot.hardware.sku"
android:requiredSystemPropertyValue="CN,haydnpro"
android:targetPackage="com.android.providers.settings" />
</manifest>

View file

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources>
<!-- Default for Settings.Global.DEVICE_NAME $1=MODEL-->
<string name="def_device_name_simple">Redmi K40 Pro+</string>
</resources>

View file

@ -0,0 +1,4 @@
runtime_resource_overlay {
name: "HaydnproCNWifiOverlay",
vendor: true
}

View file

@ -0,0 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.wifi.resources.haydnprocn"
android:versionCode="1"
android:versionName="1.0">
<application android:hasCode="false" />
<overlay
android:targetPackage="com.android.wifi.resources"
android:targetName="WifiCustomization"
android:isStatic="true"
android:requiredSystemPropertyName="ro.boot.hwc,ro.boot.hardware.sku"
android:requiredSystemPropertyValue="CN,haydnpro"
android:priority="851"/>
</manifest>

View file

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2021 The LineageOS Project
SPDX-License-Identifier: Apache-2.0
-->
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<!-- Do not translate. Default access point SSID used for tethering -->
<string name="wifi_tether_configure_ssid_default" translatable="false">Redmi K40 Pro+</string>
</resources>