Fixed minor bugs related to UI.