even so. isnt there an on activate or some similar event? if the shadow window is activated simply reactivate the main popup window. also make sure your popup window is design as an on top window (so it doesnt fall below in the z order). For permanent windows i would agree with you but a popup is only active for seconds on most occasions so the likelyhood of a problem is slim.
Of course there will always be those who may pick it apart but then again nothing you can do is flawless for those people