Refreshing subview of uiview?
I want to refresh the uiview which has uiimageview and uilabel as a subview of uiview. I don'开发者_开发百科t know how to do this.Plz help me out to do.
Thank u... Renya
For custom views, just send your view the message to refresh itself.
For Objective-C
[yourView setNeedsDisplay];
or
[yourView setNeedsDisplayInRect:aRect];
For Swift
yourView.setNeedsDisplay()
or
yourView.setNeedDisplay(aRect)
The standard views generally refresh automatically whenever you change their contents, i.e. change the text of a label or the image of an imageview.
精彩评论