You went to a party in a particularly interesting mood, and you saw happiness, and filtered through your life experience you could only feel a sense of loss.
If I were writing a book and you were one of my main characters, then the reason they would feel that way is because they actively mourning the loss/death of their own childhood. They are seeing and truly understanding for the first time exactly what they didn't have, and while they are projecting it on the real child, it is merely an embodiment of their own inner child. At 4 years old they are seeing the child as a real human being - the child has ideas, thoughts, etc that are independent from their parents. No longer babies or toddlers the child is a self-aware human being. Someone with whom they can have a conversation. Which may be why they haven't felt this way before when visiting her, in addition to the huge party.
But I'm not even a writer, nevermind a psychologist.
Still, rather than rejecting it as pointless thoughts, consider it further and see if there's something there that you might want to re-evaluate in your own life. You can't go around experiencing all the love and happiness in the world as dark foreboding shadows - it's not healthy (mentally) and to some degree it's anti-social - you may choose to avoid situations and people that might bring on these morose feelings.
Generally such feelings are important, but they are important in telling you something about yourself, not in telling you something important about someone else.
-Adam