I've made a popup view, with a UIButton on it which closes the view. Whenever I put on the button, the program quits with this message: [MTPopupWindow performSelector:withObject:withObject:]: message sent to deallocated instance 0x84675f0
Here is the header file and source file to use the class I use this line of code:
[MTPopupWindow showWindowWithContent:@"Some text here" insideView:self.view];
I thought that there was something wrong with deallocating my objects too soon but since I'm using ARC I'm not sure what is causing this problem. I think the problem is in this line of code:
[self.closeBtn addTarget:self action:@selector(closePopupWindow) forControlEvents:UIControlEventTouchUpInside];
But I don't see anything wrong with this.