Fix bug with long press. Cleanup some code.