Move the delay unit to it's own 'if' block outside of the main loop.

Since most tracks won't use a delay unit, this ensures that there will only
be one comparison operation per sample block on tracks that aren't using it.