Fixed the currently playing song not being auto selected in the playlist.

This commit is contained in:
neviyn 2016-02-28 21:28:07 +00:00
parent f97a302c79
commit 587324d5ef

View File

@ -141,7 +141,7 @@ public class PlayerGUI implements PlayerCallbackInterface, LibraryCallbackInterf
@Override @Override
public void setSongHighlighting(Song playingSong) { public void setSongHighlighting(Song playingSong) {
int index = playlistTableModel.getSongIndex(playingSong); int index = playlistTableModel.getSongIndex(playingSong);
playList.setRowSelectionInterval(index, index); SwingUtilities.invokeLater(() -> playList.setRowSelectionInterval(index, index));
playlistTableModel.setPlayingRow(index); playlistTableModel.setPlayingRow(index);
} }