It sucks, but it's biological programming for the most part. I certainly didn't find my last boyfriend because he liked what he saw when he walked by, and I'm the butt of the joke with the classy 20 somethings that populate the steam room at my pool. Fact of life.
BUT: There is some truth to the fact that when some of us gain weight, we stop putting in the physical and mental effort to make ourselves attractive. I was guilty of this. Not only did I dress like a slob, I didn't engage people, didn't use body language that welcomed conversation, etc. I was closed off.
I've NEVER gotten random male attention. Never been hit on in a bar, etc. But, I've been big since I was legal and I'm also 6 feet tall.