Yes. The speaker jack has 5 lines: Ground, Right (In), Left (In), Right (Out) and Left (Out). So the jack is also similar to a switch. No plug? Signal passes from the inputs to the outputs. Plug inserted? The outputs are disconnected/floating and the plug receives the signal.
Basically, by...