The games that support Games for Windows have a small app that runs in the background, you press the "home" button and it pauses your game and pops a small menu bar at the top of your screen, and then you can connect to GfW, giving you the same features as XBL (friends list, send emails etc.)
So your friend probably bought it through Steam and then connected to GfW once he was playing it.
View