MTK Android custom version number [Note]

2023-01-22   ES  

Add switch kcm_hide_custom_build_version, the definition version number is hidden, kcm_custom_build_display_id control system version number custom number custom number custom number custom number custom number custom number custom number custom number custom number custom number custom number custom number custom number custom number custom number custom number custom number customization

packages/apps/Settings/src/com/android/settings/DeviceInfoSettings.java

@@ -64,6 +64,8 @@ import java.util.regex.Pattern;
 import android.content.SharedPreferences;
 import android.content.pm.PackageInfo;
 //fota end
+import android.os.SystemProperties;// CUSTOM_BUILD_DISPLAY_ID

 public class DeviceInfoSettings extends SettingsPreferenceFragment implements Indexable {
 
@@ -133,7 +135,10 @@ public class DeviceInfoSettings extends SettingsPreferenceFragment implements In
         setStringSummary(KEY_DEVICE_MODEL, Build.MODEL + getMsvSuffix());
         setValueSummary(KEY_EQUIPMENT_ID, PROPERTY_EQUIPMENT_ID);
         setStringSummary(KEY_DEVICE_MODEL, Build.MODEL);
-        setStringSummary(KEY_BUILD_NUMBER, Build.DISPLAY);
+               // CUSTOM_BUILD_DISPLAY_ID
+        //setStringSummary(KEY_BUILD_NUMBER, Build.DISPLAY);
+               setStringSummary(KEY_BUILD_NUMBER, SystemProperties.get("ro.custom_kernel_version",Build.DISPLAY));
+               //modify end
         findPreference(KEY_BUILD_NUMBER).setEnabled(true);
         findPreference(KEY_KERNEL_VERSION).setSummary(getFormattedKernelVersion());

packages/apps/Settings/src/com/mediatek/settings/deviceinfo/DeviceInfoSettingsExts.java

@@ -107,6 +107,10 @@ public class DeviceInfoSettingsExts {
         if (FeatureOption.MTK_A1_FEATURE) {
             removePreference(findPreference(KEY_CUSTOM_BUILD_VERSION));
         }
+               // KCM_HIDE_CUSTOM_BUILD_VERSION
+               if (SystemProperties.get("ro.hide_custom_build_version").equals("1")){
+                       removePreference(findPreference(KEY_CUSTOM_BUILD_VERSION));
+               }
     }
 
     private void updateTitleToActivityLabel(String key) {
#KCM added by cyl hide custom build version
+ifeq ($(strip $(KCM_HIDE_CUSTOM_BUILD_VERSION)), yes)
+  PRODUCT_PROPERTY_OVERRIDES += ro.hide_custom_build_version=1
+endif
+
+#KCM custom build version
+ifeq ($(strip $(KCM_CUSTOM_BUILD_DISPLAY_ID)), yes)
+  PRODUCT_PROPERTY_OVERRIDES += ro.custom_build_display_id=1
+endif

device/along/common/ProjectConfig.mk

#kcm Custom Build Version 
 +KCM_HIDE_CUSTOM_BUILD_VERSION = NO 
 + 
 +#KCM CUSTOM Build Number Add Ro.Custom_kernel_version = xxx in the system.prop of the project 
 +KCM_CUSTOM_BUILD_DISPLAY_ID = NO

source

Random Posts

Ubuntu18.04 Conda Install CUDA and CUDNN

Define a custom event named Double_Bullet_time_finish to limit the use of super bullets #使用 Is it using a super bullet is_double_bullet = false … … in the main loop while … #Incident detection cycle: Em #The trigger super bullet end event event.type == double_bullet_time_finish: is_double_bullet = false #Super bullet effect cancellation pygame.time.set_timer (double_bullet_time_finish, 0)# Em #Draw the super bullet supply and detect whether it is obtained if bullet_supply.active: bullet_supply.move () screen.blit (bullet_supply.image, bullet_supply.rect) if pygame.sprite.collide_mask (bullet_supply, me): #Directly detect bomb_supply, whether the two elves have collided get_bullet_sound.play () # Is_double_bullet = TRUE #Start firing super bullets pygame.time.set_timer (double_bullet_time_finish, 18 * 1000) #custom event Double_bullet_time_finish will be generated after 18 seconds (after 18 seconds, the super bullet fails) bullet_supply.active = false

leetcode 146. LRU cache mechanism (two -way linked list + hash)

Android platform to get mobile phone IMSI, IMEI, serial number, and mobile phone number method

GreenPlum Move Mirror node test