Here is an app to turn off the screen with the proximity sensor. You could use this along with other apps, I believe. I did not do any development on this, but I am happy to share it. I can't remember where I found it, but it works Great! It is a superb solution to prevent accidental calls when the phone is pocketed or in a bag, pouch or if you accidently sit on it!
It is basically a screen off/lock device. It turns off the screen and locks all keys except the power button. When you turn the screen back on, you don't have to unlock it. I don't know if the key remapper program will override this or not.