Commit 8b81d883 authored by admin's avatar admin

修复按钮过小 不易点击

parent 31f0b0d4
......@@ -101,7 +101,6 @@
[_storeBtn setTitleColor:kOnLineCellTitleColor forState:UIControlStateNormal];
_storeBtn.translatesAutoresizingMaskIntoConstraints = NO;
[_storeBtn setTitle:@"商场得分" forState:UIControlStateNormal];
_storeBtn.selected = YES;
[_storeBtn setImage:[UIImage imageNamed:@"select_box"] forState:UIControlStateNormal];
[_storeBtn setImage:[UIImage imageNamed:@"no_select_box"] forState:UIControlStateSelected];
_storeBtn.titleLabel.font = [UIFont systemFontOfSize:15.0f];
......
......@@ -72,7 +72,6 @@
_scoreLabel = scoreLabel;
if (index <= 3) {
NSLog(@"indec === %d", index);
UIImageView *gradeImageView = [[UIImageView alloc] initWithImage:[UIImage imageNamed:[NSString stringWithFormat:@"medal_0%d", index]]];
[self addSubview:gradeImageView];
_gradeImageView = gradeImageView;
......
......@@ -57,6 +57,7 @@
@property (nonatomic, strong) NSMutableArray *uuidArray;
@property (nonatomic, assign) NSInteger statisMode;
@property (nonatomic) BOOL isChoose;
@end
......@@ -103,6 +104,8 @@
self.shoppingLabel.text = @"商场名称";
self.scoreLabel.text = @"总分";
self.gradeLabel.text = @"排名";
_isChoose = YES;
}
......@@ -258,16 +261,15 @@
}
- (void)statisticsClick:(UIButton *)sender
{
NSLog(@"sender.tag = %ld, _sele.tag = %ld", sender.tag, _selectButton.tag);
if (sender.tag == _selectButton.tag) {
return;
{
if (sender.tag == 323228) {
_isChoose = YES;
} else {
_selectButton.selected = NO;
sender.selected = YES;
_selectButton = (UIButton *)sender;
_isChoose = NO;
}
_selectButton = (UIButton *)sender;
[self.tableView reloadData];
}
- (void)closeBackGroundView
......@@ -348,8 +350,9 @@
cell.selectionStyle = UITableViewCellSelectionStyleNone;
} else {
[cell.storeBtn addTarget:self action:@selector(statisticsClick:) forControlEvents:UIControlEventTouchUpInside];
_selectButton = cell.storeBtn;
[cell.averageBtn addTarget:self action:@selector(statisticsClick:) forControlEvents:UIControlEventTouchUpInside];
cell.storeBtn.selected = _isChoose;
cell.averageBtn.selected = !_isChoose;
}
return cell;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment