|
@@ -181,24 +181,21 @@
|
|
|
|
|
|
- (void)countMessageWithModel:(InstrumentMessageModel *)model indexPath:(NSIndexPath *)indexPath {
|
|
|
if (model.isChoose) {
|
|
|
- if (self.chooseModel) {
|
|
|
- self.chooseModel.isChoose = NO;
|
|
|
- }
|
|
|
+ self.chooseModel = model;
|
|
|
+ self.chooseIndexPath = indexPath;
|
|
|
}
|
|
|
else {
|
|
|
- model.isChoose = NO;
|
|
|
self.chooseModel = nil;
|
|
|
self.chooseIndexPath = nil;
|
|
|
}
|
|
|
+
|
|
|
if (self.chooseIndexPath) {
|
|
|
[self.collectionView reloadItemsAtIndexPaths:@[indexPath,self.chooseIndexPath]];
|
|
|
-
|
|
|
}
|
|
|
else {
|
|
|
[self.collectionView reloadItemsAtIndexPaths:@[indexPath]];
|
|
|
}
|
|
|
- self.chooseModel = model;
|
|
|
- self.chooseIndexPath = indexPath;
|
|
|
+
|
|
|
}
|
|
|
|
|
|
- (UICollectionReusableView *)collectionView:(UICollectionView *)collectionView viewForSupplementaryElementOfKind:(NSString *)kind atIndexPath:(NSIndexPath *)indexPath {
|