This image was lost some time after publication.

It's hip to hate former mayor Willie Brown in San Francisco. How stupid. "Da Mayor" is far too smart, too charming and too awesomely impressive at political hardball to dismiss over a few foibles. The guy makes Machiavelli look like a wuss. My Slate pal Jack Shafer has noted Brown's nearly freakish IQ among dimbulb politicians. My wife says he's as sharp a dancer as he is a dresser. And oh yeah, he also passed some of California's key civil rights legislation. Basic Brown is his new memoir, cowritten with local gossip writer P.J. Corkery. The book contains this first-person account of how Brown and future martyr George Moscone tricked the California state senate into voting to abolish laws that banned common sex acts — straight, gay or otherwise. Good thing they had a helicopter handy.

In the summer of 1968, running for reelection, I attended the endorsement evening sponsored by an early gay group called Society for Individual Rights. Identify yourself as a gay person back then and you could lose your job. Teachers, police officers, firefighters, nurses, lawyers who were gay couldn't afford to join groups like SIR. But I wanted endorsements and believed in people being able to live unhindered lives.

Every candidate closed by saying, "And I will vote to enact the model penal code" — a sweeping revision of California's general penal code. Each time, the place would go ripshit crazy with applause. One of its modifications would remove criminal penalties for certain sex acts like oral copulation or anal intercourse between consenting adults. But the model penal code would involve more than 400 changes to California law. No bill that contained 400 changes was going to pass. So the pols who were up there promising weren't telling the whole truth, and they weren't really intent on solving the problem. When I rose to speak, I said, "You are interested in one section of the code only. Why don't we just move to eliminate the criminal penalties for sex acts between consenting adults?" The place really went crazy.

When decriminalization finally became law eight years later, it wasn't because there was a grand consensus. No, passing the bill required one of the most daring — and fun — political capers I ever was involved in. It wasn't all political opportunism. The legislation also emerged from a sense of outrage. My outrage. The penalties didn't affect just gays; they affected everyone. You couldn't hold a teacher's license, be a member of the bar, or hold a nurse's license if you had run afoul of this law. I represented a woman who was a passenger in a car being driven across the Golden Gate Bridge by her boyfriend. She was performing a sex act on him. The toll taker noticed and called the police. The woman lost her license as a teacher. In another case, a San Francisco man lost his professional license and livelihood because he was making out in his apartment one night with his boyfriend when a neighbor observed. To witness the scene, she had to climb up on the toilet seat in her loo, stretch to peer out a window, and then down into the window below. The guys were busted for crimes against nature.

So every year, we kept introducing the bill. By 1975, I could envisage a good result. So we went for it. George Moscone, presiding in the senate, figured out a daring way to get the bill through that house, where we figured we could get a vote of twenty for and twenty against. Like the early candidates who promised to support the reform of the entire penal code while realizing the promise was an empty gesture, many senators who were voting for the bill were actually hoping it would die in a tie.

The bill would only pass if Lieutenant Governor Mervyn Dymally broke the tie. We had to get senators to believe that would never happen. So Moscone, Dymally, and I arranged for the lieutenant governor to be on a well-publicized trip to Colorado. On that day, we brought the bill up for a voice vote in the senate [a vote in which it is not recorded who voted yea or nay]. To get the twenty pro votes, I had to convince another black, Nate Holden, to give me a commitment that if I needed his vote I could count on it. I couldn't tell Nate what the real deal was until the vote was twenty to nineteen.

After a morning of ferocious debate, people were frothing! When the vote came to twenty and twenty, Moscone did what no one expected: He locked the senators in their chamber. No one could leave. He instituted some parliamentary maneuvers to make it almost impossible for senators to change their votes. Dymally was summoned from Colorado. In those days, there were no private jets available to us. So we had to get Dymally on a commercial flight from Denver to San Francisco. Then the Highway Patrol would helicopter him into Sacramento. It took five hours.

At 7:30 p.m. Dymally entered the chamber, voted yea, and broke the tie. Sexual acts between consenting adults in California were decriminalized. In that same month, Moscone and I passed legislation to decriminalize the possession of small amounts of marijuana. Then we improved welfare benefits. None of these great social improvements would have come about unless some of us were willing to use old-fashioned skill and political daring. No progress ever takes place unless you're also willing to be tough and canny.