xdm reads ~/.xsession by default so you should create that file if it doesn’t exist. Into that you can then source your ~/.xprofile script, as in the following example:
Make sure the perms on ~/.xsession are ‘700’ octal. (u+x)
It works that way just fine for me. Where are you releasing the mouse to cancel the effect? Either way, I’d need to see your config file to be of further help.