The only person who can control gambling is ourselves and other people only through encouragement. If they do not intend to stop gambling, this urge will also have no results, unless they are taken to a rehabilitation center to be treated mentally, psychologically or with extra care under supervision. That's the only way I know to cure addicted gamblers, because I have seen several people who finally managed to get out of gambling addiction through that method.
It's similar for any addiction, not just gambling. We can only truly conquer it ourselves. It helps to distance ourselves from the environments that fuel the addiction. Going to a rehab center is also a valuable option.
it all depends on each person's thoughts, if you feel that you are able to control your emotions and control yourself when gambling, of course it doesn't matter to your wife if you know this, but not everyone has the same characteristics as you, I also have a wife and my wife always support whatever I do as long as it is within reasonable limits. My wife always reminds me to always be open in everything because the key to a harmonious household is good communication without anything being kept secret, therefore I prefer to tell my wife if I want to do it gambling and my wife also knows that gambling is a bad thing.
You're fortunate to have such a compassionate and understanding wife. Many spouses, upon discovering such issues, tend to react strongly, often issuing ultimatums. This is especially true when a significant amount of money has been lost to gambling, leaving little room for negotiation.