swift - Reset Constraints for the other components after removing a UIView
问题描述
I got a banner UIView
which I want to remove if the user has NoAds Feature.
Problem is after I remove the banner UIView
, I cant' find a way to set the constraints of the top view to wrap the rest of ViewController
.
Here are some images for you to better understand.
I remove the banner UIView
with removeFromSuperview()
method.
On the storyboard, my bottom constraint is set to 0 towards the nearest neighbour which is the UIView
banner at the time. Problem is, after I remove the Banner UIView
, I want to set the bottom constraint of the above UIView to 0 towards the SuperView.
Thanks in advance.
解决方案
推荐阅读
- java - 如何使用 rawquery 在房间库中创建表?
- nlp - NLP中下游任务的定义
- html - 导航栏初始透明并在滚动后应用线性渐变
- matlab - 访问存储在不同文件夹中的不同文件中的数据
- java - 在多个项目中使用 Java 反射的奇怪问题
- php - 如何使用 phpQuery 获取下一页 url?
- go - 接口未实现错误(缺少错误方法)
- ruby-on-rails - 我如何使用 capistrano 进行部署
- google-app-engine - gcloud app deploy 失败:来自请求 [URL] 的 [ID] 权限被拒绝
- linux - Subversion Server 使用 Active Directory 错误