This is an inherited code, I would like to change as few as possible, just give support for iphone5 (taler) screen size.
Somewhere I have a code like this:
[self.view addSubview:leftSwipedViewController.view];
The problem is: the parent UIViewController has filled out the 480×2 -> 568×2 zone ( difference between iphone4 and iphone5) the new swiped UIController will fill the 0->480×2 height zone. I would like to clear the remain space with a nice white color. How to do it?
something like [self.view clearRectangle(0,568-480,320,568, color.white)]; but this function doesn’t exist as is.
Is there any better, fast solution? – I don’t want to create a xib file for a code where the component are place from within code to X, Y coordinates.
Yes, it’s very simple actually
Right before adding your view, do this:
When you want to remove it, do this:
However, the correct approach would be to make your leftSwipedViewController support both heights