I have shared a bed with my ex after we split up (we were both still single). it was totally innocent and nothing happened. However, if i had a boyfriend, I would not share a bed with any other male no matter how much of a friend they were.
I think you seem to like this guy and you want it to mean something, but it seems like he is a pretty confused bloke who needs to decide if he wants to stay with his girlfriend or be single. He should not be sleeping in a bed with you or any other girl and 'innocently' touching your leg etc.