This expression can also be interpreted as "your happiness is my happiness", which emphasizes emotional enjoyment and interdependence, and expresses the emotional state of mutual satisfaction and mutual satisfaction.
In short, "I am happy when you are happy" is a positive, intimate and happy emotional expression, which is suitable for expressing tacit understanding and support between close friends and partners.