|
|
@@ -1,14 +1,14 @@ |
|
|
|
|
|
|
|
@interface PUCollectionView : UICollectionView
|
|
|
|
@property(assign,nonatomic) id delegate; |
|
|
|
@property(assign,nonatomic) id delegate;
|
|
|
|
@property(assign,nonatomic) NSArray* visibleCells;
|
|
|
|
@property(assign,nonatomic) NSArray* indexPathsForVisibleItems;
|
|
|
|
@property(assign,nonatomic) id reorderDelegate;
|
|
|
|
@property(assign,nonatomic) id selectionDelegate;
|
|
|
|
-(id) idexPathForItemAtPoint:(id) arg1;
|
|
|
|
-(id) cellForItemAtIndexPath:(id) arg1; |
|
|
|
-(id) cellForItemAtIndexPath:(id) arg1;
|
|
|
|
-(id) indexPathForCell:(id) arg1;
|
|
|
|
-(void) _updateVisibleCellsNow:(BOOL) arg1; |
|
|
|
-(void) _updateVisibleCellsNow:(BOOL) arg1;
|
|
|
|
|
|
|
|
@end
|
|
|
|
|
|
|
@@ -32,8 +32,8 @@ |
|
|
|
|
|
|
|
-(void)updateCtrlButton;
|
|
|
|
|
|
|
|
@end |
|
|
|
|
|
|
|
@end
|
|
|
|
|
|
|
|
@interface PUPhotosGridCell : UIView
|
|
|
|
@property(assign, nonatomic) id photoContentView;
|
|
|
|
-(void) prepareForReuse;
|
|
|
@@ -154,17 +154,17 @@ |
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
//PUPhotosGridCell* firstSelectedCell = [self cellForItemAtIndexPath:[gvController ctrlFirstIndexPath]];
|
|
|
|
PUPhotosGridCell* firstSelectedCell = [self cellForItemAtIndexPath:[gvController ctrlFirstIndexPath]];
|
|
|
|
|
|
|
|
//[firstSelectedCell.ctrlSelectOverlayView removeFromSuperview];
|
|
|
|
//firstSelectedCell.ctrlSelectOverlayView = nil;
|
|
|
|
[firstSelectedCell.ctrlSelectOverlayView removeFromSuperview];
|
|
|
|
firstSelectedCell.ctrlSelectOverlayView = nil;
|
|
|
|
|
|
|
|
NSRange indexRange;
|
|
|
|
NSInteger firstRow = [gvController ctrlFirstIndexPath].row;
|
|
|
|
NSInteger firstSection = [gvController ctrlFirstIndexPath].section;
|
|
|
|
NSInteger nextRow = nextIndexPath.row;
|
|
|
|
NSInteger nextSection = nextIndexPath.section;
|
|
|
|
|
|
|
|
|
|
|
|
NSInteger lowRow = 0;
|
|
|
|
NSInteger highRow = 0;
|
|
|
|
NSInteger lowSection = 0;
|
|
|
@@ -230,13 +230,13 @@ |
|
|
|
|
|
|
|
[gvController updateCtrlButton];
|
|
|
|
}
|
|
|
|
} |
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
-(id) dequeueReusableCellWithReuseIdentifier: (id) arg1 forIndexPath:(id) arg2{ |
|
|
|
|
|
|
|
-(id) dequeueReusableCellWithReuseIdentifier: (id) arg1 forIndexPath:(id) arg2{
|
|
|
|
id orig = %orig;
|
|
|
|
|
|
|
|
if ([self selectionDelegate] && ![self reorderDelegate] && [orig isKindOfClass:[%c(PUPhotosGridCell) class]]) { |
|
|
|
if ([self selectionDelegate] && ![self reorderDelegate] && [orig isKindOfClass:[%c(PUPhotosGridCell) class]]) {
|
|
|
|
|
|
|
|
id gvController = [self delegate];
|
|
|
|
|
|
|
@@ -249,7 +249,8 @@ |
|
|
|
NSIndexPath* firstIndexPath = [gvController ctrlFirstIndexPath];
|
|
|
|
NSIndexPath* thisIndexPath = arg2;
|
|
|
|
|
|
|
|
HBLogDebug(@"firstIndexPath: %ld-%ld thisIndexPath: %ld-%ld", (long)firstIndexPath.section, (long)firstIndexPath.row, (long)thisIndexPath.section, (long)thisIndexPath.row);
|
|
|
|
HBLogDebug(@"firstIndexPath: %ld-%ld thisIndexPath: %ld-%ld", (long)firstIndexPath.section, (long)firstIndexPath.row, (long)thisIndexPath.section, (long)thisIndexPath.row);
|
|
|
|
|
|
|
|
if ( firstIndexPath.section == thisIndexPath.section && firstIndexPath.row == thisIndexPath.row){
|
|
|
|
|
|
|
|
[orig ctrlSelectOverlayView].image = [UIImage imageWithContentsOfFile:@"/var/mobile/Library/Application Support/PhotoCtrl/check.png"];
|
|
|
@@ -259,8 +260,8 @@ |
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
return orig; |
|
|
|
} |
|
|
|
return orig;
|
|
|
|
}
|
|
|
|
|
|
|
|
%end
|
|
|
|
|