My app supports only iPhone mode, and when it runs on an iPad device, it normally displays compatible iPhone mode;
But when compatibility mode is displayed normally, everything is fine in the UI.
But my code as long as you use the AVPictureInPictureController, open the picture in picture, can lead to code for [UIScreen mainScreen] bounds will change, become the real width and height of the equipment, so the UI disorder;
Problems arise when our code is laid out with [UIScreen mainScreen] bounds.
Like this:
This was normal in iOS16 and iOS17, but suddenly it happened in iOS18
How should my application be compatible with this?