Moved the window resized event into plugin file.