Skip to content

Commit

Permalink
MD-873
Browse files Browse the repository at this point in the history
  • Loading branch information
rossetantoine committed Jan 11, 2014
1 parent 2a30d4f commit 9701f3c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions O2ViewerThumbnailsMatrix.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
BOOL avoidRecursive;
NSPoint draggingStartingPoint;
NSTimeInterval doubleClick;
NSCell *doubleClickCell;
}

@end
Expand Down
3 changes: 2 additions & 1 deletion O2ViewerThumbnailsMatrix.mm
Original file line number Diff line number Diff line change
Expand Up @@ -228,12 +228,13 @@ - (void)mouseDown:(NSEvent*)event
{
if( [cell action] && [cell target])
{
if( [NSDate timeIntervalSinceReferenceDate] - doubleClick < [NSEvent doubleClickInterval])
if( [NSDate timeIntervalSinceReferenceDate] - doubleClick < [NSEvent doubleClickInterval] && doubleClickCell == cell)
[self performSelector: @selector( actionAndFullscreen:) withObject: cell afterDelay: 0.001];
else
[[cell target] performSelector: [cell action] withObject: self afterDelay: 0.001];

doubleClick = [NSDate timeIntervalSinceReferenceDate];
doubleClickCell = cell;
}
else
[cell setHighlighted: NO];
Expand Down

0 comments on commit 9701f3c

Please sign in to comment.