Fixed the "maximizing focus bug"