jsfu/JSDropDownMenu

快速连点menu title时,会出现显示问题

Opened this issue · 0 comments

例子:快速连点同一个标题3次,本应该是显示列表,但是没有显示出来
解决方法:修改 animateBackGroundViewanimateLeftTableView 两个方法

···
[UIView animateWithDuration:0.2 animations:^{
    view.backgroundColor = [UIColor colorWithWhite:0.0 alpha:0.0];
} completion:^(BOOL finished) {
    if (!_show) { // 加上这个判断
        [view removeFromSuperview];
    }
}];
···
···
} completion:^(BOOL finished) {
    if (leftTableView && !_show) {// 加上这个判断
        [leftTableView removeFromSuperview];
    }
    if (rightTableView && !_show) {// 加上这个判断
         [rightTableView removeFromSuperview];
     }
 }];
···