Happy holidays to you too!
First, congrats on having that strong hold on your anxiety.. especially while going through a divorce, that can't be easy. I'm not a psychologist and I don't want to come off like I know everything.. but you aren't the first person who's been concerned about turning gay. I have an opinion on this though. If you think about it, most people who are gay, straight, bi, etc. probably weren't afraid that they were that orientation.. they just knew they were, right? My younger brother is gay and he hates it, he actually has said repeatedly that he wishes he was straight. I believe people who are gay are born that way and the fact that you fear being attracted to the same sex tells me that you're strictly dealing with obsessive thoughts about it.. which I'm pretty sure you understand. Although I know that can't be an easy thing to deal with, I hope you can try and keep in mind that it's only anxiety.
Also, I know that it doesn't even come close to comparing to a divorce, but when my boyfriend of three years broke up with me I definitely wasn't attracted to anyone either, just like you mentioned. I'm straight and the thought of being with another guy just disgusted me. You're just going through a difficult time and your anxiety is manifesting itself into these thoughts.
I think the only reason you can't get the images out of your head is because you're thinking about not wanting to see them. It's kind of like having a panic attack.. you think so much about not wanting to have one that you end up having one, you know? This might be horrible advice and I'm sorry if it is, but maybe try and let the images or thoughts come.. if you don't fight them they might not even come to your head.
Take care and good luck !