Rinsing the glass helps ensure that any stubborn dust etc., still left after cleaning, gets lifted away. Also, if a glass is fresh out of the dishwasher, rinsing helps cool it down. This results in the best temperature for the beer, as well as a more successful pour.
This is how it works -- or, how I understand it works: Bartenders or bar backs take a dirty beer mug, and dip it in a sink filled with a warm soapy mixture of water and cleaning solution. Occasionally, the glass is scrubbed a bit. The glass is then dunked in a second, neighboring sink of lukewarm half-soapy water.