add forgotten mofifications related to previous commit, again \o/, add some changes for window.