Think of how the windshield wipers in your car work. When you turn them off, they always go to the "park" position. You could tap the switch, and the wipers always make a full sweep. Your situation is the same, but it just happens to have two park positions.
Here is a simple illustration: it works with a system where the motor always turns the same way.
Assuming the motor is parked, it has opened one of the two normally-closed limit switches, so no power is applied to the motor until you tap the push switch. The momentary tap starts the motor moving, so the open limit switches closes, keeping the motor running until it reaches the other limit switch...
It gets more complicated if you need to reverse a DC motor.