It depends on the specific contract terms with each airline. Some agreements start the clock when the plane leaves the gate and stop when it arrives at the new gate.
Also, some international trips with layovers provide for payment of a per-diem allowance for each day a crew is gone.