rnystrom / RNGridMenu

A grid menu with elastic layout, depth of field, and realistic animation.
MIT License
1.28k stars 192 forks source link

Delegate gets released and delegate methods are not called #11

Closed phillipie99 closed 11 years ago

phillipie99 commented 11 years ago

I was having problems with the delegate methods not getting called as the delegate was being released. Changing the delegate to a strong reference in the .h fixed it.

Ex. // An optional delegate to receive information about what items were selected @property (nonatomic, strong) id delegate;

rnystrom commented 11 years ago

The only issue with this is delegates should really be weak references to avoid retain cycles. I'd be curious in learning on what type of object is delegating and how it is doing so. I'd say that this is a sign that there is some structural issues with how you've got things setup.

Feel free to post some psuedu setup.