Removed a lot of unnecessary 'new'-s
Fixed WindowLeaked exception