diff options
Diffstat (limited to 'abs/core-testing/mythtv/stable/mythvideo/mythvideo-6338-use_tmdb_in_fixes.patch')
-rw-r--r-- | abs/core-testing/mythtv/stable/mythvideo/mythvideo-6338-use_tmdb_in_fixes.patch | 151 |
1 files changed, 0 insertions, 151 deletions
diff --git a/abs/core-testing/mythtv/stable/mythvideo/mythvideo-6338-use_tmdb_in_fixes.patch b/abs/core-testing/mythtv/stable/mythvideo/mythvideo-6338-use_tmdb_in_fixes.patch deleted file mode 100644 index a5a182d..0000000 --- a/abs/core-testing/mythtv/stable/mythvideo/mythvideo-6338-use_tmdb_in_fixes.patch +++ /dev/null @@ -1,151 +0,0 @@ -Index: mythplugins/mythvideo/mythvideo/videomanager.cpp -=================================================================== ---- mythplugins.orig/mythvideo/mythvideo/videomanager.cpp 2009-03-09 22:39:40.000000000 -0400 -+++ mythplugins/mythvideo/mythvideo/videomanager.cpp 2009-03-09 23:04:55.000000000 -0400 -@@ -1535,6 +1535,56 @@ - } - } - -+ // Since there's no DB update to remove imdb.pl settings in -fixes, -+ // check for the old imdb.pl command and, if it's the old default, -+ // use tmdb.pl, instead (if available in the same location or the -+ // scripts dir)). Checks to see if cmd ends with end (the end of the -+ // old default imdb.pl command line). If so, it checks for tmdb, and -+ // if it exists in either the same location as specified in cmd or in -+ // the MythVideo scripts directory, replace end with "/tmdb.pl " + arg -+ QString UpdateCommandForTMDB(const QString cmd, const QString end, -+ const QString arg) -+ { -+ QString updated_cmd = cmd; -+ if (updated_cmd.endsWith(end)) -+ { -+ QString script_path = updated_cmd; -+ script_path.truncate(updated_cmd.findRev(end, -+ 0 - end.length())); -+ QString tmdb_path(script_path + "/tmdb.pl"); -+ if (QFile::exists(tmdb_path)) -+ { -+ VERBOSE(VB_GENERAL, QString("Overriding old default " -+ "grabber script command line. " -+ "Using tmdb.pl, instead.")); -+ updated_cmd = tmdb_path + " " + arg; -+ } -+ else -+ { -+ // It's possible the user has a non-default imdb.pl -+ // command-line--including path location--in the setting, -+ // so check to see if we've already checked the mythvideo -+ // scripts directory -+ QString def_path = QDir::cleanDirPath(QString("%1/%2") -+ .arg(gContext->GetShareDir()) -+ .arg("mythvideo/scripts")); -+ if (script_path != def_path) -+ { -+ tmdb_path = def_path + "/tmdb.pl"; -+ if (QFile::exists(tmdb_path)) -+ { -+ VERBOSE(VB_GENERAL, QString("Overriding old " -+ "default grabber script command line. " -+ "Using tmdb.pl, instead.")); -+ updated_cmd = tmdb_path + " " + arg; -+ } -+ } -+ } -+ } -+ -+ return updated_cmd; -+ } -+ - virtual void OnExecDone(bool normal_exit, const QStringList &out, - const QStringList &err) = 0; - -@@ -1624,9 +1674,16 @@ - - QString def_cmd = QDir::cleanDirPath(QString("%1/%2") - .arg(gContext->GetShareDir()) -- .arg("mythvideo/scripts/imdb.pl -M tv=no;video=no")); -+ .arg("mythvideo/scripts/tmdb.pl -M")); - -- QString cmd = gContext->GetSetting("MovieListCommandLine", def_cmd); -+ // Since there's no DB update to remove imdb.pl settings in -fixes, -+ // check for the old imdb.pl command and, if it's the old default, -+ // use tmdb.pl, instead (if available in the same location or the -+ // scripts dir)) -+ QString cmd = UpdateCommandForTMDB( -+ gContext->GetSetting("MovieListCommandLine", -+ def_cmd), -+ "/imdb.pl -M tv=no;video=no", "-M"); - - QStringList args; - args += title; -@@ -1682,9 +1739,15 @@ - - const QString def_cmd = QDir::cleanDirPath(QString("%1/%2") - .arg(gContext->GetShareDir()) -- .arg("mythvideo/scripts/imdb.pl -D")); -- const QString cmd = gContext->GetSetting("MovieDataCommandLine", -- def_cmd); -+ .arg("mythvideo/scripts/tmdb.pl -D")); -+ // Since there's no DB update to remove imdb.pl settings in -fixes, -+ // check for the old imdb.pl command and, if it's the old default, -+ // use tmdb.pl, instead (if available in the same location or the -+ // scripts dir)) -+ const QString cmd = UpdateCommandForTMDB( -+ gContext->GetSetting("MovieDataCommandLine", -+ def_cmd), -+ "/imdb.pl -D", "-D"); - - StartRun(cmd, video_uid, "Video Data Query"); - } -@@ -1726,9 +1789,16 @@ - const QString default_cmd = - QDir::cleanDirPath(QString("%1/%2") - .arg(gContext->GetShareDir()) -- .arg("mythvideo/scripts/imdb.pl -P")); -- const QString cmd = gContext->GetSetting("MoviePosterCommandLine", -- default_cmd); -+ .arg("mythvideo/scripts/tmdb.pl -P")); -+ // Since there's no DB update to remove imdb.pl settings in -fixes, -+ // check for the old imdb.pl command and, if it's the old default, -+ // use tmdb.pl, instead (if available in the same location or the -+ // scripts dir)) -+ const QString cmd = UpdateCommandForTMDB( -+ gContext->GetSetting("MoviePosterCommandLine", -+ default_cmd), -+ "/imdb.pl -P", "-P"); -+ - StartRun(cmd, video_uid, "Poster Query"); - } - -Index: mythplugins/mythvideo/mythvideo/globalsettings.cpp -=================================================================== ---- mythplugins.orig/mythvideo/mythvideo/globalsettings.cpp 2009-03-09 22:39:40.000000000 -0400 -+++ mythplugins/mythvideo/mythvideo/globalsettings.cpp 2009-03-09 22:42:47.000000000 -0400 -@@ -210,8 +210,7 @@ - { - HostLineEdit *gc = new HostLineEdit("MovieListCommandLine"); - gc->setLabel(QObject::tr("Command to search for movie listings")); -- gc->setValue(gContext->GetShareDir() + "mythvideo/scripts/imdb.pl " + -- "-M tv=no;video=no"); -+ gc->setValue(gContext->GetShareDir() + "mythvideo/scripts/tmdb.pl -M"); - gc->setHelpText(QObject::tr("This command must be " - "executable by the user running MythVideo.")); - return gc; -@@ -221,7 +220,7 @@ - { - HostLineEdit *gc = new HostLineEdit("MoviePosterCommandLine"); - gc->setLabel(QObject::tr("Command to search for movie posters")); -- gc->setValue(gContext->GetShareDir() + "mythvideo/scripts/imdb.pl -P"); -+ gc->setValue(gContext->GetShareDir() + "mythvideo/scripts/tmdb.pl -P"); - gc->setHelpText(QObject::tr("This command must be " - "executable by the user running MythVideo.")); - return gc; -@@ -231,7 +230,7 @@ - { - HostLineEdit *gc = new HostLineEdit("MovieDataCommandLine"); - gc->setLabel(QObject::tr("Command to extract data for movies")); -- gc->setValue(gContext->GetShareDir() + "mythvideo/scripts/imdb.pl -D"); -+ gc->setValue(gContext->GetShareDir() + "mythvideo/scripts/tmdb.pl -D"); - gc->setHelpText(QObject::tr("This command must be " - "executable by the user running MythVideo.")); - return gc; |