diff --git a/mythtv/programs/mythfrontend/commandlineparser.cpp b/mythtv/programs/mythfrontend/commandlineparser.cpp
index 7321510..fed9eca 100644
|
a
|
b
|
void MythFrontendCommandLineParser::LoadArguments(void)
|
| 29 | 29 | "Always prompt for backend selection.", ""); |
| 30 | 30 | add(QStringList( QStringList() << "-d" << "--disable-autodiscovery" ), |
| 31 | 31 | "noautodiscovery", false, "Prevent frontend from using UPnP autodiscovery.", ""); |
| | 32 | add("--jumppoint", "jumppoint", "", "Start the frontend at a Jump Point.", "") |
| | 33 | ->SetBlocks("runplugin")->SetGroup("Startup Behavior"); |
| | 34 | add("--runplugin", "runplugin", "", "Run a plugin right away.", "") |
| | 35 | ->SetBlocks("jumppoint")->SetGroup("Startup Behavior"); |
| 32 | 36 | } |
| 33 | 37 | |
| 34 | 38 | QString MythFrontendCommandLineParser::GetHelpHeader(void) const |
diff --git a/mythtv/programs/mythfrontend/main.cpp b/mythtv/programs/mythfrontend/main.cpp
index 599f493..054c897 100644
|
a
|
b
|
int main(int argc, char **argv)
|
| 1463 | 1463 | new QApplication(argc, argv); |
| 1464 | 1464 | QCoreApplication::setApplicationName(MYTH_APPNAME_MYTHFRONTEND); |
| 1465 | 1465 | |
| 1466 | | QString pluginname; |
| 1467 | | |
| 1468 | | QFileInfo finfo(qApp->argv()[0]); |
| 1469 | | QString binname = finfo.baseName(); |
| 1470 | | |
| 1471 | 1466 | int retval; |
| 1472 | 1467 | if ((retval = cmdline.ConfigureLogging()) != GENERIC_EXIT_OK) |
| 1473 | 1468 | return retval; |
| 1474 | 1469 | |
| 1475 | 1470 | bool ResetSettings = false; |
| 1476 | 1471 | |
| 1477 | | if (binname.toLower() != "mythfrontend") |
| 1478 | | pluginname = binname; |
| 1479 | | |
| 1480 | 1472 | if (cmdline.toBool("prompt")) |
| 1481 | 1473 | bPromptForBackend = true; |
| 1482 | 1474 | if (cmdline.toBool("noautodiscovery")) |
| … |
… |
int main(int argc, char **argv)
|
| 1524 | 1516 | if (cmdline.toBool("reset")) |
| 1525 | 1517 | ResetSettings = true; |
| 1526 | 1518 | |
| 1527 | | if (cmdline.GetArgs().size() >= 1) |
| 1528 | | pluginname = cmdline.GetArgs()[0]; |
| 1529 | | |
| 1530 | 1519 | QString fileprefix = GetConfDir(); |
| 1531 | 1520 | |
| 1532 | 1521 | QDir dir(fileprefix); |
| … |
… |
int main(int argc, char **argv)
|
| 1614 | 1603 | pmanager = new MythPluginManager(); |
| 1615 | 1604 | gContext->SetPluginManager(pmanager); |
| 1616 | 1605 | |
| 1617 | | if (pluginname.size()) |
| | 1606 | if (cmdline.toBool("runplugin") && !cmdline.toString("runplugin").isEmpty()) |
| 1618 | 1607 | { |
| 1619 | | if (pmanager->run_plugin(pluginname) || |
| 1620 | | pmanager->run_plugin("myth" + pluginname)) |
| | 1608 | if (!pmanager->run_plugin(cmdline.toString("runplugin")) || |
| | 1609 | !pmanager->run_plugin("myth" + cmdline.toString("runplugin"))) |
| 1621 | 1610 | { |
| 1622 | 1611 | qApp->exec(); |
| 1623 | 1612 | |
| … |
… |
int main(int argc, char **argv)
|
| 1679 | 1668 | PreviewGeneratorQueue::CreatePreviewGeneratorQueue( |
| 1680 | 1669 | PreviewGenerator::kRemote, 50, 60); |
| 1681 | 1670 | |
| | 1671 | if (cmdline.toBool("jumppoint") && !cmdline.toString("jumppoint").isEmpty()) |
| | 1672 | { |
| | 1673 | GetMythMainWindow()->JumpTo(cmdline.toString("jumppoint"), false); |
| | 1674 | } |
| | 1675 | |
| 1682 | 1676 | int ret = qApp->exec(); |
| 1683 | 1677 | |
| 1684 | 1678 | PreviewGeneratorQueue::TeardownPreviewGeneratorQueue(); |