losing window as a local variable for AMD's sake