Maybe look at it like you were fulfilling an emotional need for a while, until he felt that you weren't. His gamblng losses weren't your responsibility, though he unfairly placed them upon you. Maybe you could have validated better, but who knows. He chose to play a game where the house always wins in the end. That's on him.
Turkish is right. People with Cluster B disorders use outside stimulus to manage their internal state. Your ex wasn't faking seeming stable -- you were, for a while, the drug that made him feel stable. The gambling may have further destabilized him, or the positive effects of your relationship wore off. It is not likely that your ex was consciously faking stability for the first part of the relationship.