Permalink
Browse files

added: advancedsettings.xml option <tvmultipartmatching> in order to …

…modify the default multipart enumeration regexp
  • Loading branch information...
vdrfan
vdrfan committed Mar 2, 2011
1 parent 4d453f3 commit eaa64a3c13599fe321a413a31ca97ddababc3d1d
Showing with 10 additions and 2 deletions.
  1. +3 −0 xbmc/settings/AdvancedSettings.cpp
  2. +7 −2 xbmc/video/VideoInfoScanner.cpp
@@ -742,6 +742,9 @@ bool CAdvancedSettings::Load()
if (pTVStacking)
GetCustomTVRegexps(pTVStacking, m_tvshowStackRegExps);
+ //tv multipart enumeration regexp
+ XMLUtils::GetString(pRootElement, "tvmultipartmatching", m_tvshowMultiPartEnumRegExp);
+
// path substitutions
TiXmlElement* pPathSubstitution = pRootElement->FirstChildElement("pathsubstitution");
if (pPathSubstitution)
@@ -923,7 +923,11 @@ namespace VIDEO
(regexppos >= 0 && regexp2pos == -1))
{
GetEpisodeAndSeasonFromRegExp(reg, episode);
- CLog::Log(LOGDEBUG, "VideoInfoScanner: Adding new season %u, multipart episode %u", episode.iSeason, episode.iEpisode);
+
+ CLog::Log(LOGDEBUG, "VideoInfoScanner: Adding new season %u, multipart episode %u [%s]",
+ episode.iSeason, episode.iEpisode,
+ g_advancedSettings.m_tvshowMultiPartEnumRegExp.c_str());
+
episodeList.push_back(episode);
free(remainder);
remainder = reg.GetReplaceString("\\3");
@@ -935,7 +939,8 @@ namespace VIDEO
char *ep = reg2.GetReplaceString("\\1");
episode.iEpisode = atoi(ep);
free(ep);
- CLog::Log(LOGDEBUG, "VideoInfoScanner: Adding multipart episode %u", episode.iEpisode);
+ CLog::Log(LOGDEBUG, "VideoInfoScanner: Adding multipart episode %u [%s]",
+ episode.iEpisode, g_advancedSettings.m_tvshowMultiPartEnumRegExp.c_str());
episodeList.push_back(episode);
offset += regexp2pos + reg2.GetFindLen();
}

0 comments on commit eaa64a3

Please sign in to comment.