The reference to the UIView class has some change in the observed kvo.
By implementing -(void)willRemoveSubview:(UIView *)subview
, you can see the opposite.
UPDATE After reading the explanation:
I hope I understood correctly. I did something similar, but with a UITableView, not a UIScrollView (but they are exactly the same).
It was like a pop-up detailed view. I decided how you already did this by adding a detailed view to the UITableView supervisor, and then I added a UIButton closure in the detailed view with the corresponding IBOutlet:
@interface CustomUIView : UIView @property(nonatomic,weak) IBOutlet UIButtonView *closingButton; -(void)closeDetail:(IBAction)action; @end
and the action was simple:
-(void)closeDetail:(IBAction)action {
sdsds
source share