Reverted saveScreenState to BufWinLeave and fixed bug causing errors.

The reason of the error messages with BufWinLeave was that current buffer may differ from one being unloaded.
Here is note from BufWinLeave help:
>NOTE: When this autocommand is executed, the
>current buffer "%" may be different from the
>buffer being unloaded "\<afile\>".

I didn't look down into codes, but based on "saveScreenState()" name BufWinLeave is more appropriate, since it called only once when buffer is closed.