I am following a tutorial and I am a bit confused on this line of code...
sideView.frame = CGRectMake(gesture.direction == UISwipeGestureRecognizerDirectionRight ? -swipedCell.frame.size.width : swipedCell.frame.size.width, swipedCell.frame.origin.y, swipedCell.frame.size.width, swipedCell.frame.size.height);
What does gesture.direction == UISwipeGestureRecognizerDirectionRight ? -swipedCell.frame.size.width :
mean?
I have never seen it in my experience. What does the ==
and ? -
and :
mean in this statement? Or could you explain the whole thing? What would this make the frame if I swiped left, and right?
Thanks a lot.