His second remark, however, is clearly innuendo. And that was described as having diffused the situation. As a reader, the first remark did not affect me, but this second one absolutely does feel weird and inappropriate.
All of which probably illustrates that I lack social awareness, but for some reason I find this example very confusing.
The issue is in his next comment when he jokes about Heidi handling his dick frequently. Yes, yes, it's a joke, so it's different from doing something physical like putting her hand on his crotch. But in telling the joke, he paints a picture of the one female in the room in a sexual position. Many people would be uncomfortable about that, even embarrassed. It's not a professional thing to do.