gui/movieplayer.cpp: fix audio/subtitle pid reset on title change

This commit is contained in:
[CST] Focus
2014-02-21 16:56:04 +04:00
parent 71b550b04b
commit b100766c97

View File

@@ -1367,6 +1367,8 @@ void CMoviePlayerGui::selectChapter()
playback->SetPosition(positions[select], true);
} else if (pselect >= 0) {
numsubs = numpida = 0;
currentspid = -1;
currentapid = 0;
playback->SetTitle(playlists[pselect]);
}
}
@@ -1599,6 +1601,11 @@ void CMoviePlayerGui::selectAutoLang()
std::map<std::string, std::string>::const_iterator it;
for(it = iso639.begin(); it != iso639.end(); ++it) {
if (g_settings.pref_lang[i] == it->second && strncasecmp(language[j].c_str(), it->first.c_str(), 3) == 0) {
bool enabled = true;
// TODO: better check of supported
std::string audioname;
addAudioFormat(j, audioname, enabled);
if (enabled)
pref_idx = j;
break;
}