Can you tell whether the windows are being closed/parted and then opened again?
Also, when you say "all windows", do you mean the status window as well? Query windows? Or just channel windows? that are being restored.
It sounds like the bouncer or bridge is parting all channels and then joining all channels again, in which case there is nothing mIRC can do.