The worst is, "Cheer up! It might not happen!"
I may, or may not, have occasionally snapped back viciously with, "It already did, a$$hole!"
Why on earth would a perfect stranger say that to someone? I never would. Usually, I think, it's well-meaning but can they not see that if someone truly was upset, it would be a horrible thing to say, and if someone wasn't upset, it would be patronising? I don't understand the thing with constantly verifying other people's state of being - though I have had to learn to adopt it.
It's just a (profoundly annoying) NT thing, a very short "yes" will usually shut them down in my experience.