1. When you won enough and you are happy with the profits so leave the game and stay from any casino with your profit. Have fun and don't let it taken back to you.
2. When you have lost enough, you have to take a rest and forget that you have gambled that time so chasing the losses won't trigger you.
Well said dude, the only thing that will push us to continue to play is our own greed. Whenever we felt loosing on the game, we tend to think to play even more just to recover those losses and it can also apply when you already won and you wanted to earn more profits.