Yes and no. That's certainly a factor, but outside of work, people also tend to stay pretty close to their neighborhoods (I've been able to walk to my grocery store in the last 3 neighborhoods I've lived in). There's also been substantial work to build new mass transit, but housing hasn't increased substantially around the transit stops.
Edit: I'm referring to LA. My impression is SF is small enough that this isn't a big issue.