在项目工程中设置titleView为searchBar,导航栏的高度变化,之前的64变化为76,


修改代码如下
if #available(iOS 11.0, *) {
searchBar.heightAnchor.constraint(equalToConstant: 44.0).isActive = true
}
现在的导航栏是正常的
在项目工程中设置titleView为searchBar,导航栏的高度变化,之前的64变化为76,
修改代码如下
if #available(iOS 11.0, *) {
searchBar.heightAnchor.constraint(equalToConstant: 44.0).isActive = true
}
现在的导航栏是正常的
本文标题:Swift中titleView添加searchBar导航栏变高的
本文链接:https://www.haomeiwen.com/subject/wkspqftx.html
网友评论