This thread
will give you some pointers for how to do it.
(There are other examples in the forum - just do a search for long press)
long press
For more information, see the wiki Searching the Forum for Answers section.