I want my subclass of UIView to automatically position itself when it is added to the view of the parent container.
Is there any way to determine when it will be added and run my positioning code, or do I need to do something like this?
[parentView addSubview:subView]; [setView calcPosition];
source share