AudioMixerSettings::AudioMixerSettings() : TriggeredConfigurationGroup(false, true, false, false) { setLabel(QObject::tr("Audio Mixer")); setUseLabel(false); Setting *volumeControl = MythControlsVolume(); addChild(volumeControl); // Mixer settings ConfigurationGroup *settings = new VerticalConfigurationGroup(false, true, false, false); settings->addChild(MixerDevice()); settings->addChild(MixerControl()); settings->addChild(MixerVolume()); settings->addChild(PCMVolume()); ConfigurationGroup *dummy = new VerticalConfigurationGroup(false, true, false, false); // Show Mixer config only if internal volume controls enabled setTrigger(volumeControl); addTarget("0", dummy); addTarget("1", settings); }
GalleryConfigurationGroup() : TriggeredConfigurationGroup(false, true, false, false) { setLabel(QObject::tr("MythGallery Settings (Slideshow)")); setUseLabel(false); #ifdef USING_OPENGL HostCheckBox* useOpenGL = SlideshowUseOpenGL(); addChild(useOpenGL); setTrigger(useOpenGL); ConfigurationGroup* openGLConfig = new VerticalConfigurationGroup(false); openGLConfig->addChild(SlideshowOpenGLTransition()); openGLConfig->addChild(SlideshowOpenGLTransitionLength()); addTarget("1", openGLConfig); #endif ConfigurationGroup* regularConfig = new VerticalConfigurationGroup(false); regularConfig->addChild(MythGalleryOverlayCaption()); regularConfig->addChild(SlideshowTransition()); regularConfig->addChild(SlideshowBackground()); addTarget("0", regularConfig); addChild(SlideshowDelay()); addChild(SlideshowRecursive()); }
ChannelOptionsFilters::ChannelOptionsFilters(const ChannelID& id) : VerticalConfigurationGroup(false, true, false, false) { setLabel(QObject::tr("Channel Options - Filters")); setUseLabel(false); addChild(new VideoFilters(id)); addChild(new OutputFilters(id)); }
ChannelOptionsFilters::ChannelOptionsFilters(const ChannelID& id) : VerticalConfigurationGroup(false, true, false, false) { setLabel(QCoreApplication::translate("(ChannelSettings)", "Channel Options - Filters")); setUseLabel(false); addChild(new VideoFilters(id)); addChild(new OutputFilters(id)); }
ChannelOptionsV4L::ChannelOptionsV4L(const ChannelID& id) : VerticalConfigurationGroup(false, true, false, false) { setLabel(QObject::tr("Channel Options - Video 4 Linux")); setUseLabel(false); addChild(new Freqid(id)); addChild(new Finetune(id)); addChild(new Contrast(id)); addChild(new Brightness(id)); addChild(new Colour(id)); addChild(new Hue(id)); };
ChannelOptionsV4L::ChannelOptionsV4L(const ChannelID& id) : VerticalConfigurationGroup(false, true, false, false) { setLabel(QCoreApplication::translate("(ChannelSettings)", "Channel Options - Video4Linux")); setUseLabel(false); addChild(new Freqid(id)); addChild(new Finetune(id)); addChild(new Contrast(id)); addChild(new Brightness(id)); addChild(new Colour(id)); addChild(new Hue(id)); };
ChannelOptionsCommon::ChannelOptionsCommon(const ChannelID &id, uint default_sourceid) : VerticalConfigurationGroup(false, true, false, false) { setLabel(QCoreApplication::translate("(ChannelSettings)", "Channel Options - Common")); setUseLabel(false); addChild(new Name(id)); Source *source = new Source(id, default_sourceid); source->Load(); HorizontalConfigurationGroup *group1 = new HorizontalConfigurationGroup(false,false,true,true); VerticalConfigurationGroup *bottomhoz = new VerticalConfigurationGroup(false, true); VerticalConfigurationGroup *left = new VerticalConfigurationGroup(false, true); VerticalConfigurationGroup *right = new VerticalConfigurationGroup(false, true); left->addChild(new Channum(id)); left->addChild(new Callsign(id)); left->addChild(new Visible(id)); right->addChild(source); right->addChild(new ChannelTVFormat(id)); right->addChild(new Priority(id)); group1->addChild(left); group1->addChild(right); bottomhoz->addChild(onairguide = new OnAirGuide(id)); bottomhoz->addChild(xmltvID = new XmltvID(id, source->getSelectionLabel())); bottomhoz->addChild(new TimeOffset(id)); addChild(group1); addChild(new CommMethod(id)); addChild(new Icon(id)); addChild(bottomhoz); connect(onairguide, SIGNAL(valueChanged( bool)), this, SLOT( onAirGuideChanged(bool))); connect(source, SIGNAL(valueChanged( const QString&)), this, SLOT( sourceChanged(const QString&))); };
MythFillSettings() : TriggeredConfigurationGroup(false, true, false, false) { setLabel(QObject::tr("Program Schedule Downloading Options")); setUseLabel(false); Setting* fillEnabled = MythFillEnabled(); addChild(fillEnabled); setTrigger(fillEnabled); ConfigurationGroup* settings = new VerticalConfigurationGroup(false); settings->addChild(MythFillDatabasePath()); settings->addChild(MythFillDatabaseArgs()); settings->addChild(MythFillMinHour()); settings->addChild(MythFillMaxHour()); settings->addChild(MythFillGrabberSuggestsTime()); addTarget("1", settings); // show nothing if fillEnabled is off addTarget("0", new VerticalConfigurationGroup(true)); };
ChannelOptionsRawTS::ChannelOptionsRawTS(const ChannelID &id) : VerticalConfigurationGroup(false, true, false, false), cid(id) { setLabel(QCoreApplication::translate("(ChannelSettings)", "Channel Options - Raw Transport Stream")); setUseLabel(false); const uint mx = kMaxPIDs; pids.resize(mx); sids.resize(mx); pcrs.resize(mx); for (uint i = 0; i < mx; i++) { HorizontalConfigurationGroup *row = new HorizontalConfigurationGroup(false, false, true, true); TransLabelSetting *label0 = new TransLabelSetting(); label0->setLabel(" PID"); TransLabelSetting *label1 = new TransLabelSetting(); label1->setLabel(" StreamID"); TransLabelSetting *label2 = new TransLabelSetting(); label2->setLabel(" Is PCR"); row->addChild(label0); row->addChild((pids[i] = new TransLineEditSetting())); row->addChild(label1); row->addChild((sids[i] = new TransComboBoxSetting())); for (uint j = 0x101; j <= 0x1ff; j++) { QString desc = StreamID::GetDescription(j&0xff); if (!desc.isEmpty()) sids[i]->addSelection( QString("%1 (0x%2)") .arg(desc).arg(j&0xff,2,16,QLatin1Char('0')), QString::number(j), false); } for (uint j = 0x101; j <= 0x1ff; j++) { QString desc = StreamID::GetDescription(j&0xff); if (desc.isEmpty()) sids[i]->addSelection( QString("0x%1").arg(j&0xff,2,16,QLatin1Char('0')), QString::number(j), false); } /* we don't allow tables right now, PAT & PMT generated on the fly for (uint j = 0; j <= 0xff; j++) { QString desc = TableID::GetDescription(j); if (!desc.isEmpty()) { sids[i]->addSelection( QString("%1 (0x%2)").arg(j,0,16,QLatin1Char('0')), QString::number(j), false); } } */ row->addChild(label2); row->addChild((pcrs[i] = new TransCheckBoxSetting())); addChild(row); } };
AudioConfigSettings::AudioConfigSettings(ConfigurationWizard *parent) : VerticalConfigurationGroup(false, true, false, false), m_OutputDevice(NULL), m_MaxAudioChannels(NULL), m_AudioUpmix(NULL), m_AudioUpmixType(NULL), m_AC3PassThrough(NULL), m_DTSPassThrough(NULL), m_EAC3PassThrough(NULL),m_TrueHDPassThrough(NULL), m_DTSHDPassThrough(NULL), m_parent(parent) { setLabel(QObject::tr("Audio System")); setUseLabel(false); ConfigurationGroup *devicegroup = new HorizontalConfigurationGroup(false, false); devicegroup->addChild((m_OutputDevice = new AudioDeviceComboBox(this))); // Rescan button TransButtonSetting *rescan = new TransButtonSetting("rescan"); rescan->setLabel(QObject::tr("Rescan")); rescan->setHelpText(QObject::tr("Rescan for available audio devices. " "Current entry will be checked and " "capability entries populated.")); devicegroup->addChild(rescan); connect(rescan, SIGNAL(pressed()), this, SLOT(AudioRescan())); addChild(devicegroup); QString name = m_OutputDevice->getValue(); AudioOutput::AudioDeviceConfig *adc = AudioOutput::GetAudioDeviceConfig(name, name, true); if (adc->settings.IsInvalid()) { LOG(VB_GENERAL, LOG_ERR, QString("Audio device %1 isn't usable Check audio configuration") .arg(name)); } audiodevs.insert(name, *adc); devices.append(*adc); delete adc; ConfigurationGroup *maingroup = new VerticalConfigurationGroup(false, false); addChild(maingroup); m_triggerDigital = new TransCheckBoxSetting(); m_AC3PassThrough = AC3PassThrough(); m_DTSPassThrough = DTSPassThrough(); m_EAC3PassThrough = EAC3PassThrough(); m_TrueHDPassThrough = TrueHDPassThrough(); m_DTSHDPassThrough = DTSHDPassThrough(); m_cgsettings = new HorizontalConfigurationGroup(); m_cgsettings->setLabel(QObject::tr("Digital Audio Capabilities")); m_cgsettings->addChild(m_AC3PassThrough); m_cgsettings->addChild(m_DTSPassThrough); m_cgsettings->addChild(m_EAC3PassThrough); m_cgsettings->addChild(m_TrueHDPassThrough); m_cgsettings->addChild(m_DTSHDPassThrough); TriggeredItem *sub1 = new TriggeredItem(m_triggerDigital, m_cgsettings); maingroup->addChild(sub1); maingroup->addChild((m_MaxAudioChannels = MaxAudioChannels())); maingroup->addChild((m_AudioUpmix = AudioUpmix())); maingroup->addChild((m_AudioUpmixType = AudioUpmixType())); TransButtonSetting *test = new TransButtonSetting("test"); test->setLabel(QObject::tr("Test")); test->setHelpText(QObject::tr("Will play a test pattern on all configured " "speakers")); connect(test, SIGNAL(pressed()), this, SLOT(StartAudioTest())); addChild(test); TransButtonSetting *advanced = new TransButtonSetting("advanced"); advanced->setLabel(QObject::tr("Advanced Audio Settings")); advanced->setHelpText(QObject::tr("Enable extra audio settings. Under most " "usage all options should be left alone")); connect(advanced, SIGNAL(pressed()), this, SLOT(AudioAdvanced())); addChild(advanced); // Set slots connect(m_MaxAudioChannels, SIGNAL(valueChanged(const QString&)), this, SLOT(UpdateVisibility(const QString&))); connect(m_OutputDevice, SIGNAL(valueChanged(const QString&)), this, SLOT(UpdateCapabilities(const QString&))); connect(m_AC3PassThrough, SIGNAL(valueChanged(const QString&)), this, SLOT(UpdateCapabilities(const QString&))); connect(m_DTSPassThrough, SIGNAL(valueChanged(const QString&)), this, SLOT(UpdateCapabilities(const QString&))); connect(m_EAC3PassThrough, SIGNAL(valueChanged(const QString&)), this, SLOT(UpdateCapabilities(const QString&))); connect(m_TrueHDPassThrough, SIGNAL(valueChanged(const QString&)), this, SLOT(UpdateCapabilities(const QString&))); connect(m_DTSHDPassThrough, SIGNAL(valueChanged(const QString&)), this, SLOT(UpdateCapabilities(const QString&))); AudioRescan(); }
ChannelScannerGUIScanPane::ChannelScannerGUIScanPane( bool lock, bool strength, bool snr, bool rotorpos, QObject *target, const char *slot) : VerticalConfigurationGroup(false, false, true, true), ss(NULL), sn(NULL), pos(NULL), progressBar(NULL), sl(NULL), sta(NULL) { setLabel(tr("Scan Progress")); ConfigurationGroup *slg = new HorizontalConfigurationGroup(false, false, true, true); slg->addChild(sta = new TransLabelSetting()); sta->setLabel(tr("Status")); sta->setValue(tr("Tuning")); if (lock) { slg->addChild(sl = new TransLabelSetting()); sl->setValue(" " " "); } addChild(slg); if (rotorpos) { addChild(pos = new TransProgressSetting()); pos->setLabel(tr("Rotor Movement")); } ConfigurationGroup *ssg = NULL; if (strength || snr) ssg = new HorizontalConfigurationGroup(false, false, true, true); if (strength) { ssg->addChild(ss = new TransProgressSetting()); ss->setLabel(tr("Signal Strength")); } if (snr) { ssg->addChild(sn = new TransProgressSetting()); sn->setLabel(tr("Signal/Noise")); } if (strength || snr) addChild(ssg); addChild(progressBar = new TransProgressSetting()); progressBar->setValue(0); progressBar->setLabel(tr("Scan")); addChild(log = new LogList()); TransButtonSetting *cancel = new TransButtonSetting(); cancel->setLabel(tr("Stop Scan")); addChild(cancel); connect(cancel, SIGNAL(pressed(void)), target, slot); //Seem to need to do this as the constructor doesn't seem enough setUseLabel(false); setUseFrame(false); }