Modification of UITableView frame with animation problem

I tried to change the animation of the UITableView frame in many ways, but when I reduce the table view, the animation is not smooth, first the contents of the cell disappear, and only after that the frame changes. Since I saw that this problem is only present in the older OS, from iOS 3.2 this problem is fixed. Can someone tell me a workaround for this animation to work fine on an older OS as well?

thank

+3
source share
1 answer

One way to fix the problem is to take a screenshot from the current view.

   UIGraphicsBeginImageContext(self.view.bounds.size);     
    [self.view.layer renderInContext:UIGraphicsGetCurrentContext()];  
    UIImage *viewImage                  = UIGraphicsGetImageFromCurrentImageContext();  
    UIGraphicsEndImageContext(); 

. .

0

Source: https://habr.com/ru/post/1756576/


All Articles