-
Notifications
You must be signed in to change notification settings - Fork 19
Closed
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation
Description
- 在 UIViewController 中设置
edgesForExtendedLayout = UIRectEdge(rawValue: 0)
属性,并且使用 IQKeyboardManager 框架的同时键盘没有收起,此时返回上级页面 NXNavigationBar 会出现错位的现象。这是 IQKeyboardManager 框架本身处理这种情况就有问题(设置edgesForExtendedLayout = UIRectEdge(rawValue: 0)
属性,键盘没收起时返回上级页面导致界面下移的问题),NXNavigationExtension 框架内部无法处理这种情况(其实已经最大程度适配 IQKeyboardManager 框架)。
解决方法:
- 不要设置
edgesForExtendedLayout = UIRectEdge(rawValue: 0)
,保持edgesForExtendedLayout
默认值即可。 - 不使用 IQKeyboardManager 框架(或者在使用的 UIViewController 中暂时禁用 IQKeyboardManager 框架)。
- 在 UIViewController 中不使用 UITextField/UITextView 等需要弹出键盘的控件。
- 在 UIViewController 中设置
edgesForExtendedLayout = UIRectEdge(rawValue: 0)
属性,并且使用 NXNavigationBar 本身或者contentView
中添加需要用户交互的控件时,里面添加的控件将无法接受到用户事件的响应(控件展示没有问题),但是添加没有用户交互事件的控件是不受限制的,比如在 ViewController04_CustomNavigationBar 中设置edgesForExtendedLayout = UIRectEdge(rawValue: 0)
属性时,NXNavigationBar 上面的按钮将无法点击。
解决方法:
- 不要设置
edgesForExtendedLayout = UIRectEdge(rawValue: 0)
,保持edgesForExtendedLayout
默认值即可。 - 不要在 NXNavigationBar 本身或者
contentView
中添加需要用户交互的控件。
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation