fix isNormalWindow for dialog