I would feel that it means the same for anyone who has been hiding what they feel inside. When you come out of the closet you are opening the door to let anyone else know what you feel inside.
I think it applies generally to making a previously secret activity public but I think usually applies to publically acknowledging being LGBT. I’m not sure actually which usage came first.