Choosing happiness while loved one struggles?

a friend of mine is generally happy except when she is with her husband and he is depressed (a lot of the time) She said she CAN’T be happy then. Like it is impossible. Is this really a choice? How does one be happy when someone you love is really suffering?