Fixed a bug that caused SMO to crash when closing the main window, completed style revision