The proposed purchase of the N.B.A.’s Dallas Mavericks by a casino operator is the latest sign of how fully leagues have embraced the gaming world.For years, professional sports organizations like the National Basketball Association and Major League Baseball prohibited liquor companies from buying advertising in locations in stadiums and arenas that could be seen on television, in deference to efforts to curb drunken driving.But in 2009, during the depths of the worst recession since the Great Depression, those same leagues found themselves scrambling for cash as their biggest sponsors — automakers, banks and others — cut back on marketing. Suddenly, they began signing multimillion-dollar deals with companies that made rum, tequila, vodka and other hard liquor, and the advertising was displayed for all to see.It was a sign of how justifications can change seemingly overnight, especially when money is involved. The sports world was reminded of that last week when Miriam Adelson and her trust sold $2 billion worth of shares in the Sands Corporation, a casino operator, to buy a professional sports team, which turned out to be the Dallas Mavericks. (The purchase still needs to be approved by the league’s board of governors before becoming official.)“The Adelson and Dumont families are honored to have the opportunity to be stewards of this great franchise,” they said in a statement.For decades, most major professional leagues largely kept the gaming world at arm’s length. They barred players, referees and owners from gambling on sports, to insulate game results from any hint of impropriety, a stance that dated back at least a century to the famed Black Sox scandal of 1919.Some leagues likewise forbid owners from holding stakes in casinos. In one instance, Dan Rooney, the principal owner of the National Football League’s Pittsburgh Steelers, had to buy out his brothers’ stake in the team because the brothers owned racetracks in New York and Florida. The N.B.A. had no such rule and has had owners with ties to casinos, including Tilman Fertitta, the current owner of the Houston Rockets.The N.F.L. commissioner, Roger Goodell, long opposed the broad legalization of sports gambling.Adam Hunger/Associated Press“If gambling is permitted freely on sporting events, normal incidents of the game such as bad snaps, dropped passes, turnovers, penalties and play calling inevitably will fuel speculation, distrust and accusations of point-shaving or game fixing,” the N.F.L. commissioner, Roger Goodell, said in 2012.Yet at a time when sports gambling — once done only in casino meccas like Las Vegas or through bookies — has been legalized in dozens of states, the leagues’ former approach seems quaint. While restrictions remain on players, referees and owners wagering on their own sports, gambling has otherwise been embraced by the mainstream sports establishment.They have removed restrictions on casinos and sports books advertising in stadiums and on television. Some stadiums, like FedEx Field in Landover, Md., the home of the N.F.L.’s Washington Commanders, have sports books inside. Sports wagering companies now plaster their names on sign boards in stadiums and buy TV commercials during games, including the Super Bowl, with all manner of promotions to woo new customers.The leagues have also done an about-face on operating in the home of sports wagering, Las Vegas, which was for years off limits. Now the National Hockey League, the Women’s National Basketball Association and the N.F.L. have teams in the city. Last month, Major League Baseball’s owners unanimously approved allowing the A’s to leave Oakland and head to Las Vegas. The N.B.A., which has held All-Star games, summer leagues and a new in-season tournament in Las Vegas, could add an expansion team in the city in the coming years, which would give every major pro sport a team in a locale the leagues once shunned.“The leagues are constantly re-evaluating their business as laws change, social mores change and different companies and categories become bigger,” said Marc Ganis, a consultant to numerous teams and leagues. “That includes look at ownership rules, sponsorships and advertising.”The N.F.L.’s embrace of Las Vegas has perhaps been most surprising, given the league’s conservative reputation. The Raiders won approval to move to the city in 2017. The league has held the Pro Bowl and college draft on The Strip. And in February, the league’s marquee event — the Super Bowl — will be played in Las Vegas, removing perhaps the last vestige of any distance between it and the city.The Super Bowl in February will be held at Allegiant Stadium in Las Vegas.Kirby Lee/Usa Today Sports Via Reuters ConThe leagues’ reassessment has been both practical and strategic. The biggest break came in 2018 after the Supreme Court ruled that a law that prohibited sports gambling in most of the country was unconstitutional. Dozens of states quickly approved legalizing sports wagering, dwarfing the amount spent in Las Vegas. The N.F.L. now allows owners to hold stakes in casinos that have no sports betting, though it restricts owners from having more than a 5 percent stake in casinos that allow sports betting.“Las Vegas is acceptable not so much because of us but because gambling is almost everywhere now,” said Michael Green, a historian at the University of Nevada, Las Vegas. “The Strip is as legit as any large business.”At the same time, Las Vegas’s image as a desert oasis with casinos and nightclubs under the thumb of the mob changed dramatically in the 1990s, when The Strip was turned into an urban theme park where parents could bring their children. Many visitors come now as much to see shows like U2 at the Sphere or the latest extravaganza by Cirque du Soleil as they do to visit the casinos.And while Las Vegas is relatively small, with a population of about 2.5 million in the region, it has been able to support teams like the Raiders and the Golden Knights of the N.H.L. because the city is a year-round destination, drawing roughly 40 million tourists annually.“There’s a whole new demographic being exposed to sports gambling by visiting Las Vegas,” said Jay Kornegay, the vice president of the Race and Sports Book Operations at Westgate Resorts.Mr. Green noted that the Smith Center for the Performing Arts and the Mob Museum, which both opened in 2012, also gave the city a glean of sophistication it had lacked. He recalled how just 20 years ago, the N.F.L. blocked Las Vegas from buying ads during the Super Bowl, a decision that now seems antiquated.“Remind me,” he said, “where’s the next Super Bowl?”Kevin Draper More