The only way to keep a secret for long periods is that few know about it.
Not that I believe that there's a secret button.
Interestingly enough, most classified information doesn't get leaked the same way that Snowden leaked his documents. It's mostly due to carelessness. The best example of this is deployment schedules. One of my coworkers was scheduled to go on a Marine Expeditionary Unit (ship that goes around the Pacific just in case something happens). The date of departure was classified. Someone told his wife, who told all of her friends on Facebook. Oops.
Trying to keep a "detain"-button secret, having it manned by thousands of people that only have a high school diploma OR a year of work experience in security/aviation/screening, doesn't sound easy (those are by the way the education requirements for a TSO according to usajobs.gov). Since a leak could stem from a minor overstep of their contract (ohh, I told a buddy about it, big deal right?), and there are frequent policy violations by agents, it does look grim for the existence of such a button.
I heard of them kicking the machines to make them go off though, so there's a "button", and it's public knowledge that they will use it if they want a pat down.
Indeed, the narrative of this very story seemed to be overwhelmingly focused on figuring out why he was setting off the explosives detectors. They repeatedly went through his belongings and tried to figure out if he was indeed in the business of making explosions. They almost certainly used a secret warrant to go into his apartment to, again, see if there was an explosives lab there. They really thought they had something when the explosives detector found something it didn't like, and there is no rational reason they would do this just because someone was Muslim (again, Muslims make hundreds of millions of flights in the US -- do people seriously think this is what they go through?)