These change a bunch of assignments to calls to set the current window correctly...