When it effects you I do think a person can say something if they cannot make a change where it won't effect you.
For instance, if you are around a smoker you can choose to get off the elevator and take another one.
If a person near you is smoking you can choose to move to another place all the time.
If you are in someone's home where they smoke, well, you went there to see them so suck it up.
My blister on my back during allergy testing was from tobacco. I had to have an eppi shot before they'd let me drive home. Now that was a trip. Driving home shaking and heart pounding, beating out of my chest.
That blister was almost 5 inches across. It puffed up immediately when they brushed to allergen on my roughed up skin. It burned and itched.
One of the ladies leaders in my old church gave me 3 people on my visiting list that smoked. When I went a few times and came out having to do a breathing treatment I told her I couldn't visit them anymore she told me in a sarcastic way "Well, everyone's allergic to cigarette smoke" and that I had been assigned to visit them. So needless to say they didn't get visited and I asked to be released from ever having to go visit anyone again and I no longer attend that church.
So you have a choice. In this instance, you could tell he was smoking or that he had just put out a cigarette. You could have pushed the button for the next floor, got off, then turned around and pushed the button to ride the elevator the next time.
You could have just rode in silence, you said something and I don't think it was wrong if you were asked.