需求:通过 shell 命令 wm size 查看到 Physical Size (物理尺寸) 1080x2246 ,将初始化的这个物理分辨率进行修改指定的分辨率;
通过命令 wm size <width>x<height> 只能修改的是Override size的尺寸,也叫做覆盖尺寸。
修改原因:因为有些app 在获取设备的分辨率的时候,大部分会获取当前分辨率 ,也就是如果有Overide size的时候用overide size
没有用physical size 尺寸。
如下所示:
具体步骤:需要修改的文件如下所示
修改: device/mediateksample/R60/ProjectConfig.mk
修改: device/mediateksample/R60/system.prop
修改: frameworks/base/packages/SettingsProvider/res/values/defaults.xml
修改: frameworks/base/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
修改: kernel-4.4/arch/arm64/boot/dts/mediatek/R60.dts
修改: kernel-4.4/arch/arm64/configs/R60_debug_defconfig
修改: kernel-4.4/arch/arm64/configs/R60_defconfig
修改: kernel-4.4/drivers/misc/mediatek/lcm/ft8719_fhdpp_dsi_vdo/ft8719_fhdpp_dsi_vdo.c
修改: kernel-4.4/drivers/misc/mediatek/lcm/h618dax01_fhdpp_dsi_vdo/h618dax01_fhdpp_dsi_vdo.c
修改: vendor/mediatek/proprietary/bootable/bootloader/lk/dev/lcm/ft8719_fhdpp_dsi_vdo/ft8719_fhdpp_dsi_vdo.c
修改: vendor/mediatek/proprietary/bootable/bootloader/lk/dev/lcm/h618dax01_fhdpp_dsi_vdo/h618dax01_fhdpp_dsi_vdo.c
-
修改: device/mediateksample/R60/ProjectConfig.mk
-
修改: device/mediateksample/R60/system.prop
-
修改 frameworks/base/packages/SettingsProvider/res/values/defaults.xml
修改: frameworks/base/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
修改: kernel-4.4/arch/arm64/boot/dts/mediatek/R60.dts
修改: kernel-4.4/arch/arm64/configs/R60_debug_defconfig
修改: kernel-4.4/arch/arm64/configs/R60_defconfig
修改: kernel-4.4/drivers/misc/mediatek/lcm/ft8719_fhdpp_dsi_vdo/ft8719_fhdpp_dsi_vdo.c
修改: kernel-4.4/drivers/misc/mediatek/lcm/h618dax01_fhdpp_dsi_vdo/h618dax01_fhdpp_dsi_vdo.c
修改: vendor/mediatek/proprietary/bootable/bootloader/lk/dev/lcm/ft8719_fhdpp_dsi_vdo/ft8719_fhdpp_dsi_vdo.c
修改: vendor/mediatek/proprietary/bootable/bootloader/lk/dev/lcm/h618dax01_fhdpp_dsi_vdo/h618dax01_fhdpp_dsi_vdo.c