Ticket #3753: mythbackend-settings-cleanup-180707.diff
File mythbackend-settings-cleanup-180707.diff, 9.2 KB (added by , 17 years ago) |
---|
-
mythtv/programs/mythtv-setup/backendsettings.cpp
10 10 static HostLineEdit *LocalServerIP() 11 11 { 12 12 HostLineEdit *gc = new HostLineEdit("BackendServerIP"); 13 gc->setLabel(QObject::tr("IP address for") + QString(" ") + 14 gContext->GetHostName()); 13 gc->setLabel(QObject::tr("IP address")); 15 14 gc->setValue("127.0.0.1"); 16 15 gc->setHelpText(QObject::tr("Enter the IP address of this machine. " 17 16 "Use an externally accessible address (ie, not " … … 23 22 static HostLineEdit *LocalServerPort() 24 23 { 25 24 HostLineEdit *gc = new HostLineEdit("BackendServerPort"); 26 gc->setLabel(QObject::tr("Port the server runs on"));25 gc->setLabel(QObject::tr("Port")); 27 26 gc->setValue("6543"); 28 27 gc->setHelpText(QObject::tr("Unless you've got good reason to, don't " 29 28 "change this.")); … … 33 32 static HostLineEdit *LocalStatusPort() 34 33 { 35 34 HostLineEdit *gc = new HostLineEdit("BackendStatusPort"); 36 gc->setLabel(QObject::tr(" Port the server shows status on"));35 gc->setLabel(QObject::tr("Status Port")); 37 36 gc->setValue("6544"); 38 37 gc->setHelpText(QObject::tr("Port which the server will listen to for " 39 38 "HTTP requests. Currently, it shows a little status " … … 44 43 static GlobalLineEdit *MasterServerIP() 45 44 { 46 45 GlobalLineEdit *gc = new GlobalLineEdit("MasterServerIP"); 47 gc->setLabel(QObject::tr(" Master ServerIP address"));46 gc->setLabel(QObject::tr("IP address")); 48 47 gc->setValue("127.0.0.1"); 49 48 gc->setHelpText(QObject::tr("The IP address of the master backend " 50 49 "server. All frontend and non-master backend machines " … … 57 56 static GlobalLineEdit *MasterServerPort() 58 57 { 59 58 GlobalLineEdit *gc = new GlobalLineEdit("MasterServerPort"); 60 gc->setLabel(QObject::tr("Port the master server runs on"));59 gc->setLabel(QObject::tr("Port")); 61 60 gc->setValue("6543"); 62 61 gc->setHelpText(QObject::tr("Unless you've got good reason to, " 63 62 "don't change this.")); 64 63 return gc; 65 64 }; 66 65 66 static HostLineEdit *LocalSecurityPin() 67 { 68 HostLineEdit *gc = new HostLineEdit("SecurityPin"); 69 gc->setLabel(QObject::tr("Security Pin (Required)")); 70 gc->setValue(""); 71 gc->setHelpText(QObject::tr("Pin code required for a frontend to connect " 72 "to the backend. Blank prevents all " 73 "connections, 0000 allows any client to " 74 "connect.")); 75 return gc; 76 }; 77 67 78 static GlobalComboBox *TVFormat() 68 79 { 69 80 GlobalComboBox *gc = new GlobalComboBox("TVFormat"); … … 282 293 static GlobalSpinBox *WOLbackendReconnectWaitTime() 283 294 { 284 295 GlobalSpinBox *gc = new GlobalSpinBox("WOLbackendReconnectWaitTime", 0, 1200, 5); 285 gc->setLabel(QObject::tr(" Reconnect wait time(secs)"));296 gc->setLabel(QObject::tr("Delay between wake attempts (secs)")); 286 297 gc->setValue(0); 287 298 gc->setHelpText(QObject::tr("Length of time the frontend waits between " 288 299 "tries to wake up the master backend. This should be the " … … 294 305 static GlobalSpinBox *WOLbackendConnectRetry() 295 306 { 296 307 GlobalSpinBox *gc = new GlobalSpinBox("WOLbackendConnectRetry", 1, 60, 1); 297 gc->setLabel(QObject::tr(" Count of reconnect tries"));308 gc->setLabel(QObject::tr("Wake Attempts")); 298 309 gc->setHelpText(QObject::tr("Number of times the frontend will try to wake " 299 310 "up the master backend.")); 300 311 gc->setValue(5); … … 307 318 gc->setLabel(QObject::tr("Wake Command")); 308 319 gc->setValue(""); 309 320 gc->setHelpText(QObject::tr("The command used to wake up your master " 310 "backend server ."));321 "backend server\n(eg. sudo /etc/init.d/mythtv-backend restart).")); 311 322 return gc; 312 323 }; 313 324 314 325 static GlobalLineEdit *WOLslaveBackendsCommand() 315 326 { 316 327 GlobalLineEdit *gc = new GlobalLineEdit("WOLslaveBackendsCommand"); 317 gc->setLabel(QObject::tr("Wake command for slaves"));328 gc->setLabel(QObject::tr("Wake command")); 318 329 gc->setValue(""); 319 330 gc->setHelpText(QObject::tr("The command used to wakeup your slave " 320 331 "backends. Leave empty to disable.")); … … 324 335 static GlobalSpinBox *idleTimeoutSecs() 325 336 { 326 337 GlobalSpinBox *gc = new GlobalSpinBox("idleTimeoutSecs", 0, 1200, 5); 327 gc->setLabel(QObject::tr("Idle timeout (secs)"));338 gc->setLabel(QObject::tr("Idle shutdown timeout (secs)")); 328 339 gc->setValue(0); 329 340 gc->setHelpText(QObject::tr("The amount of time the master backend idles " 330 341 "before it shuts down all backends. Set to 0 to disable " … … 368 379 static GlobalLineEdit *SetWakeuptimeCommand() 369 380 { 370 381 GlobalLineEdit *gc = new GlobalLineEdit("SetWakeuptimeCommand"); 371 gc->setLabel(QObject::tr(" Set wakeuptime command"));382 gc->setLabel(QObject::tr("Command to set Wakeup Time")); 372 383 gc->setValue(""); 373 gc->setHelpText(QObject::tr("The command used to set the time (passed as "374 "$time) to wake up the masterbackend"));384 gc->setHelpText(QObject::tr("The command used to set the wakeup time (passed as " 385 "$time) for the Master Backend")); 375 386 return gc; 376 387 }; 377 388 … … 476 487 static GlobalCheckBox *JobsRunOnRecordHost() 477 488 { 478 489 GlobalCheckBox *gc = new GlobalCheckBox("JobsRunOnRecordHost"); 479 gc->setLabel(QObject::tr("Run Jobs only on original recording host"));490 gc->setLabel(QObject::tr("Run Jobs only on original recording backend")); 480 491 gc->setValue(false); 481 492 gc->setHelpText(QObject::tr("If set, jobs in the queue will be required " 482 493 "to run on the backend that made the " … … 670 681 BackendSettings::BackendSettings() { 671 682 VerticalConfigurationGroup* server = new VerticalConfigurationGroup(false); 672 683 server->setLabel(QObject::tr("Host Address Backend Setup")); 673 server->addChild(LocalServerIP()); 674 server->addChild(LocalServerPort()); 675 server->addChild(LocalStatusPort()); 676 server->addChild(MasterServerIP()); 677 server->addChild(MasterServerPort()); 684 VerticalConfigurationGroup* localServer = new VerticalConfigurationGroup(); 685 localServer->setLabel(QObject::tr("Local Backend" + QString(" (") + gContext->GetHostName() + QString(")"))); 686 localServer->addChild(LocalServerIP()); 687 localServer->addChild(LocalServerPort()); 688 localServer->addChild(LocalStatusPort()); 689 localServer->addChild(LocalSecurityPin()); 690 VerticalConfigurationGroup* masterServer = new VerticalConfigurationGroup(); 691 masterServer->setLabel(QObject::tr("Master Backend")); 692 masterServer->addChild(MasterServerIP()); 693 masterServer->addChild(MasterServerPort()); 694 server->addChild(localServer); 695 server->addChild(masterServer); 678 696 addChild(server); 679 697 698 VerticalConfigurationGroup* locale = new VerticalConfigurationGroup(false); 699 locale->setLabel(QObject::tr("Locale Settings")); 700 locale->addChild(TVFormat()); 701 locale->addChild(VbiFormat()); 702 locale->addChild(FreqTable()); 703 locale->addChild(TimeOffset()); 704 addChild(locale); 705 680 706 VerticalConfigurationGroup* group2 = new VerticalConfigurationGroup(false); 681 group2->setLabel(QObject::tr("Backend Setup")); 682 group2->addChild(TVFormat()); 683 group2->addChild(VbiFormat()); 684 group2->addChild(FreqTable()); 685 group2->addChild(TimeOffset()); 707 group2->setLabel(QObject::tr("File Management Settings")); 686 708 group2->addChild(MasterBackendOverride()); 687 709 group2->addChild(DeletesFollowLinks()); 688 710 group2->addChild(TruncateDeletes()); … … 710 732 addChild(group3); 711 733 712 734 VerticalConfigurationGroup* group4 = new VerticalConfigurationGroup(false); 713 group4->setLabel(QObject::tr(" WakeOnLansettings"));735 group4->setLabel(QObject::tr("Backend Wakeup settings")); 714 736 715 737 VerticalConfigurationGroup* backend = new VerticalConfigurationGroup(); 716 backend->setLabel(QObject::tr("Master Backend"));738 backend->setLabel(QObject::tr("Master Backend")); 717 739 backend->addChild(WOLbackendReconnectWaitTime()); 718 740 backend->addChild(WOLbackendConnectRetry()); 719 741 backend->addChild(WOLbackendCommand()); 720 742 group4->addChild(backend); 721 743 722 group4->addChild(WOLslaveBackendsCommand()); 744 VerticalConfigurationGroup* slaveBackend = new VerticalConfigurationGroup(); 745 slaveBackend->setLabel(QObject::tr("Slave Backends")); 746 slaveBackend->addChild(WOLslaveBackendsCommand()); 747 group4->addChild(slaveBackend); 723 748 addChild(group4); 724 749 725 750 VerticalConfigurationGroup* group5 = new VerticalConfigurationGroup(false); 726 group5->setLabel(QObject::tr("Job Queue ( Host-Specific)"));751 group5->setLabel(QObject::tr("Job Queue (Backend-Specific)")); 727 752 group5->addChild(JobQueueMaxSimultaneousJobs()); 728 753 group5->addChild(JobQueueCheckFrequency()); 729 754