minor cleanup in UI code