You don't even need the raw commands.
The GetPointerClick() And GetPointerReleazsed() commands should be used. Get the position of the cursor when GetPointerClick() is true, then get the position when GetPointerReleazsed() is true. Subtract one set of coord from another to get a distance vector, then put them into ATanFull to get a swipe direction.
THats what I do in the game i'm creating to open/close the pause menu. (Like the notification window on Android) and to close the game. (Like closing apps on WebOS)
I'll post an example when I'm on my other laptop...