Once the closing command is given to the breaker, the resistor is first connected across the contacts. This resistance in series limits the line current. A few milliseconds later, the contacts are closed.
While opening the breaker, the pre-insertion resistor is first disconnected before the contacts are opened by the circuit breaker. Pre-insertion resistors are also used in lines which have transformers to limit the high inrush current.