Cleaned up info_selected() and chart_selected().