God for you for saying something to your boss! What a creep! It sounds like he was just power tripping and I am glad you recognize it for what it is. Hopefully he'll mellow out and act nicer with you going forward.
As for you ex, if he didn't recognize the rare gem he had when he was with you, then he isn't worthy of you. Don't waste your energy worrying about him. Someone better will show up in your life now that you have room for them.