I need to set the height of a subview to be proportional to its parent. On iPads, I need it to be one third of the height while on iPhones I need it to be one half. In the "AnyAny" size class, I create the constraint and set the multiplier to 0.3333333. This does what it should on iPads. When I change the size class to "CompactRegular", I change the multiplier of the constraint to 0.5. Although this makes it half on iPhones, it also does it for iPads. How do I make it such that the size classes would have different multipliers?
相关问题
- CALayer - backgroundColor flipped?
- Core Data lightweight migration crashes after App
- Core Data lightweight migration crashes after App
- How can I implement password recovery in an iPhone
- State preservation and restoration strategies with
相关文章
- 现在使用swift开发ios应用好还是swift?
- UITableView dragging distance with UIRefreshContro
- Could I create “Call” button in HTML 5 IPhone appl
- TCC __TCCAccessRequest_block_invoke
- Where does a host app handle NSExtensionContext#co
- Unable to process app at this time due to a genera
- Swift - hide pickerView after value selected
- How do you detect key up / key down events from a
You'll need to add a new constraint for Compact/Regular, and make sure the original one is only installed in Any/Any like so: