Fixed destroy of windows using 'X'