The description by ladyridge is exactly how it works. Another thing to note is that the auto up feature on the driver's side window has a sensor that causes the window to return back down to the mid way point; it won't go all the way down, only half way. It kicks in if it "feels" something between the down position and shut position.
This acts as a safety device should you attempt to close the window with the auto up feature and your hand, arm, finger or whatever is in the way. It works too. In fact, it works too well. I installed window visors of the in-channel variety and sometimes (not always), the window will touch the in channel part of the visor and cause it to come back down to the mid way point. This feature is disabled if you "manually" close the window by holding the lever up to the first position and not going as far as the auto up mode.