void HandleLongPress (UILongPressGestureRecognizer gestureRecognizer)
{
if (IsSyncing)
return;
if (gestureRecognizer.State == UIGestureRecognizerState.Began) {
var p = gestureRecognizer.LocationInView ((UIView)docsView);
var item = docsView.GetItemAtPoint (Praeclarum.Graphics.RectangleEx.ToPointF (p));
if (item == null)
return;
if (!Editing && !selecting) {
SetEditing (true, true);
}
docsView.SelectedDocuments.Add (item.Reference.File.Path);
}
//
// CGPoint p = [gestureRecognizer locationInView:self.collectionView];
//
// NSIndexPath *indexPath = [self.collectionView indexPathForItemAtPoint:p];
// if (indexPath == nil){
// NSLog(@" couldn't find index path");
// } else {
// // get the cell at indexPath (the one you long pressed)
// UICollectionViewCell* cell =
// [self.collectionView cellForItemAtIndexPath:indexPath];
// // do stuff with the cell
// }
}