Using Auto Layout constraints, I am trying to set up a subview with a vertical position that never changes, even when the in-call status bar (or some other non-standard status bar) is showing. I don't want to position the view relative to the Bottom Layout Guide because I want its y-coordinate to be the same for 3.5" and 4" devices.
Here's an illustration of what I want to have happen:
Initially, I set up the subview with a "Top Space to: Top Layout Guide" constraint for its y-position. With this configuration, the In-Call Status Bar pushed the subview 20px downward:
Next, I tried replacing that constraint with "Top Space to: Superview," where Superview was the root view of the controller. No change. Is there some other way to maintain a constant y-position for a view with Auto Layout constraints? I know I could resort to handling this manually by subscribing to UIApplicationDidChangeStatusBarFrameNotification
, but I'd like to keep things simple if I can.