IFMMenu icon indicating copy to clipboard operation
IFMMenu copied to clipboard

performSelector: withObject的问题

Open huangzhifei opened this issue 8 years ago • 0 comments

在 IFMMenuContainerView 的单击手势里面使用了 performSelector: withObject 去 dismiss ,这里何不直接调用?使用 performSelector: withObject 去传bool值,接受方的参数是需要使用NSNumber的,比如加一个这样的私有方法

  • (void)dismissMenuWithNumber:(NSNumber *)flag { BOOL animated = [flag boolValue]; [self dismissMenu:animated]; }

或者不如直接 IFMMenuView *targetView = (IFMMenuView *)subview; [targetView dismissMenu:YES];

huangzhifei avatar Nov 29 '17 09:11 huangzhifei