clean window resource