I'll address this 2 ways.
1) I wouldn't buy a gift for an ex-baby momma. Even if we are cordial. I would feel like she's in my past and I just want her to be good to my child and help raise her right. Period.
2) What exactly is your current wife's problem? That you bought your child's mother a gift? Or was she upset at the types of gifts you bought your child's mother?
A) If she's upset that you bought her perfume, that I can understand because some gifts can be interpreted as more intimate than others.
B) If she's upset that you bought her a gift, period...then I have to say...your current wife is just being a c*nt. You're a grown ass man and she's the mother of your child. Furthermore, you spend your god damn money how ever the f*ck you damn well see fit.