Gesture input, fixed error sorting items