So, we all have yetzer. As Jews, we believe that yetzer is part of our condition; reference the midrash about the disastrous effects of disabling it temporarily (Yoma 69b).
It's all of our job to recognize yetzer and deal with it. That, of course, includes avoiding some situations, channeling some urges, but, at the end of the day, taking responsibility for our own actions, and realizing that we choose. We are never 'at the mercy' of it.
There's no difference between a co-worker with shapely ankles and a valuable object sitting unattended. There's really no difference between a co-worker with shapely ankles and a co-worker with cleavage. Any of those, and a host of other things, are yetzer-fodder. It is each person's responsibility to do the right thing regardless of the constant parade of temptation in the world.
Most of us, most of the time, have no problem resisting the urge to pick up someone else's pen, let alone coat or camera. The behavior that results by following a sexual urge is likely to be at least as bad in any number of dimensions. So, the question almost turns itself on its head. No one thinks that they need to write a question here asking, 'Why am I having so much trouble avoiding the urge to steal my co-worker's wallet? How can I resist that urge?' What is it that makes people like that OP from Workplace think that this is any more complex than that?
If there's a 'trick' here, it's to recognize that the procreative urge is just another urge, and if you detach yourself and observe yourself (a bit of anti-devekut), you can say to yourself, 'oh, I see, yetzer is very busy with this one. OK, back to work.' It's interesting that this came from 'Workplace', since the workplace is an endless set of opportunities to learn to self-observe and thus get better self-control.
Some additional context: in traditional Jewish thought, and somewhat contrary to some of what I wrote above, sexual temptation is the sine qua non of temptation. (e.g. Kiddushin 81a.) To deal with it, traditional communities build some very extensive fences:
- get married promptly
- don't be alone with a woman you're not married to
- don't even look (mehitza, etc)
- in a few extreme communities, insist that the married women in your community shave their heads even under their wigs
- (as per other answers) remove glasses strategically
All in all, build a closed community with a set of practices that help hold temptation at bay. This is all of limited utility to people who aren't part of those communities. My remarks above are addressed to people like me who want to apply the underlying categories of Jewish morality to life where you might have a co-worker who typically shows the nape of her neck (to reference another culture's area of emphasis) or a bit of some other bits.
"reactions"
are you referring to?