We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(void)viewDidLoad {
[super viewDidLoad]; UIButton *btn = [[UIButton alloc]initWithFrame:CGRectMake(100, 700, 60, 30)]; [btn setBackgroundColor:[UIColor blueColor]]; [btn addTarget:self action:@selector(clickItem) forControlEvents:UIControlEventTouchUpInside]; [self.view addSubview:btn]; self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc]initWithTitle:@"筛选" style:UIBarButtonItemStylePlain target:self action:@selector(clickItem)]; }
(void)clickItem { NSLog(@"1"); GHDropMenuModel *configuration = [[GHDropMenuModel alloc]init];
configuration.titles = [configuration creaFilterDropMenuData]; /** 配置筛选菜单是否记录用户选中 默认NO */ configuration.recordSeleted = NO;
weakself(self); GHDropMenu *dropMenu = [GHDropMenu creatDropFilterMenuWidthConfiguration:configuration dropMenuTagArrayBlock:^(NSArray * _Nonnull tagArray) { [weakSelf getStrWith:tagArray];
}]; dropMenu.titleSeletedImageName = @"up_normal"; dropMenu.titleNormalImageName = @"down_normal"; dropMenu.delegate = self; dropMenu.durationTime = 0.5; self.dropMenu = dropMenu; [dropMenu show];
}
The text was updated successfully, but these errors were encountered:
正常来说你每次点击button都会响应 1.查看你的button响应事件 2.configuration.titles = [configuration creaFilterDropMenuData]; 你选择构造这种模型是侧边弹出的菜单,只有点击的时候可以弹出,弹出后button是被覆盖在蒙版后面的,是点不到的
Sorry, something went wrong.
那怎么才能在button的点击事件里获取到筛选菜单收回的方法?
能否在外部也能调用dismiss方法,我尝试了一下没有效果,点击不能收回
No branches or pull requests
(void)viewDidLoad {
[super viewDidLoad];
UIButton *btn = [[UIButton alloc]initWithFrame:CGRectMake(100, 700, 60, 30)];
[btn setBackgroundColor:[UIColor blueColor]];
[btn addTarget:self action:@selector(clickItem) forControlEvents:UIControlEventTouchUpInside];
[self.view addSubview:btn];
self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc]initWithTitle:@"筛选" style:UIBarButtonItemStylePlain target:self action:@selector(clickItem)];
}
(void)clickItem {
NSLog(@"1");
GHDropMenuModel *configuration = [[GHDropMenuModel alloc]init];
configuration.titles = [configuration creaFilterDropMenuData];
/** 配置筛选菜单是否记录用户选中 默认NO */
configuration.recordSeleted = NO;
weakself(self);
GHDropMenu *dropMenu = [GHDropMenu creatDropFilterMenuWidthConfiguration:configuration dropMenuTagArrayBlock:^(NSArray * _Nonnull tagArray) {
[weakSelf getStrWith:tagArray];
}];
dropMenu.titleSeletedImageName = @"up_normal";
dropMenu.titleNormalImageName = @"down_normal";
dropMenu.delegate = self;
dropMenu.durationTime = 0.5;
self.dropMenu = dropMenu;
[dropMenu show];
}
The text was updated successfully, but these errors were encountered: