Hi,
I also had problems with the camera taking photos in my poket, but I use Tasker and Screen Off and Lock.
If the proximity sensor is active (set a variable) when camera starts I go to home screen and then run Screen Off and Lock.
I do the same if Quick Memo starts.
/Henrik