Added shifting of windows
Fixed indentation