Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iOS 12 及以下,在 rootViewController、以 animated:NO 进行的 push/pop 界面,titleViewTintColor 无效 #1190

Closed
renyufei8023 opened this issue Jan 26, 2021 · 3 comments
Labels
Projects

Comments

@renyufei8023
Copy link

renyufei8023 commented Jan 26, 2021

Bug 表现
QMUINavigationControllerDelegate 里的 titleViewTintColor 在 iOS 12 下如果应用于 rootViewController、被 animated:NO push/pop 出来的界面里会失效。
不管是 QMUINavigationTitleView 或系统 title 都会。

其他信息

  • 设备: All
  • iOS 版本: iOS 12 及以下
  • QMUI 版本: 4.2.2
@MoLice

This comment has been minimized.

@MoLice MoLice closed this as completed Mar 16, 2021
@MoLice MoLice changed the title titleViewTintColor在iOS12设备下不起作用 iOS 12 及以下,在 rootViewController、以 animated:NO 进行的 push/pop 界面,titleViewTintColor 无效 Mar 19, 2021
@MoLice
Copy link
Collaborator

MoLice commented Mar 19, 2021

对于 iOS 12,在 QMUI 里 viewWillAppear: 时会调用 renderNavigationTitleStyleAnimated 来更新 titleView 的样式,需要满足条件:

但对于 rootViewController,或者被以 animated:NO 方式 push/pop 过去的界面,他们的 push/pop 动作会立即完成,然后才开始走到 viewWillAppear:,这意味着截图里的 navigationAction 在此时是 Unknow(因为 push/pop completed 之后就会转为 Unknow),由于不满足条件,所以无法执行 renderNavigationTitleStyleAnimated

新版本将会修复该问题,在此之前你可以将本地代码的 qmui_navigationAction >= QMUINavigationActionWillPush 改为 qmui_navigationAction >= QMUINavigationActionUnknow

@MoLice MoLice reopened this Mar 19, 2021
@MoLice MoLice added this to Done in 4.2.3 Mar 26, 2021
@MoLice
Copy link
Collaborator

MoLice commented Mar 31, 2021

已发布 4.2.3 修复该问题。

@MoLice MoLice closed this as completed Mar 31, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
No open projects
4.2.3
Done
Development

No branches or pull requests

2 participants