Ex picked our daughter up today yelling at her because she was upset

My 5 year old daughter has been really whiny lately. She will start crying over silly things and pout and then refuse get up. My ex and I switch off every Thursday. She was upset because she couldn't bring her toy to school. It makes too much noise and it's a distraction. She threw a fit and sat down and refused to get up. Her dad came and I told him what's going on. He said he was going to be late for work and I said she's having one of her moments. He said he's not doing this today. She's been acting like this for a month and hes over it. He went in my house. Went up to our daughter and said "Allazai! Fix it! And pointed out the door. She got up crying and went to the car. I said he didn't have to raise his voice at her like that and he said he's been patient with her and he's not doing this today. Talking to her like that scared her. I understand we lose our patience as parents but he doesn't even sound sorry.