AndroidAutoSize icon indicating copy to clipboard operation
AndroidAutoSize copied to clipboard

screenWidthDp、screenHeightDp设置和还原没有考虑横竖屏切换情况吗?

Open start141 opened this issue 1 year ago • 0 comments

Environment

  • [x] Autosize Version: v1.2.1
  • [x] Target Android Version: 无关
  • [x] Device Model: 无关
  • [x] Device Resolution: 无关
  • [x] Design Size On AndroidManifest: 无关

Bug Description:

screenWidthDp和screenHeightDp的大小是会随着横竖屏切换时来回变化的,而阅读AndroidAutoSize源码发现: 1、autoConvertDensity好像没有在横竖屏切换onConfigurationChanged时更新screenWidthDp和screenHeightDp。 2、cancelAdapt时好像也没有根据横竖屏设置不同的screenWidthDp和screenHeightDp值。(使用的是固定的InitScreenWidthDp、InitScreenHeightDp)

start141 avatar Sep 02 '24 11:09 start141