-
-
Save gliubc/9977bb97566326975cfd8d90756b499c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 视图自适应屏幕宽度 | |
CGRect frame = self.view.frame; | |
frame.size.width = UIScreen.mainScreen.bounds.size.width; | |
self.view.frame = frame; | |
[self.view layoutIfNeeded]; | |
// 单元格自适应屏幕宽度 | |
CGRect frame = self.frame; | |
frame.size.width = UIScreen.mainScreen.bounds.size.width; | |
self.frame = frame; | |
[self layoutIfNeeded]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment