Okay with the new system, lets see some scenarios...
Race 1:
Driver one pits at half distance for his mandatory stop, but crosses the line on the track.
Driver two pits at 3/4 distance for his mandatory stop, but gets damaged at start of final lap, necessitating a pitstop. He crosses the line in the pits.
Driver three plans to pit on penultimate lap, but gets stop-go penalty. LFS realises it's the penultimate lap, so converts it to a +15 sec penalty. He crosses the line on the track.
Driver 4 plans to pit on penultimate lap, but misses pitlane (forgetful :P), and ends up pitting on the final lap (nearly running out of fuel). Mandatory pitstop not made in 'window', so he is DQ'd.
Driver 1: 1 Visit to pits within window
Driver 2: 2 Visits to pit, one within window - not DQ'd
Driver 3: 1 Visit to pit, within window, plus an added time penalty
Driver 4: 1 Visit to pits, Not within window, DQ'd.
It's okay to FINISH the race in the pits, but NOT okay to Finish in the pitlane during a MANDATORY pitstop.
Having a window, even as simple as not 1st lap or last lap (you're own last lap, not the leaders last lap) would stop 'cheating' and make everyone have more fun. If the 'windows' were configurable that'd be even better.
Of course, people would end up wanting pit apples instead of pit windows, or even pit linux's occasionally. But we can't cater for ALL tastes :P