[vlc-commits] Qt4: add ATSC and CQAM to open dialog
Rémi Denis-Courmont
git at videolan.org
Thu Mar 24 19:20:31 CET 2011
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Mar 24 16:52:20 2011 +0200| [5206e96482da0624ebf0ea5ca8f800fcfe69275b] | committer: Rémi Denis-Courmont
Qt4: add ATSC and CQAM to open dialog
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=5206e96482da0624ebf0ea5ca8f800fcfe69275b
---
modules/gui/qt4/components/open_panels.cpp | 37 +++++++++++++++++----------
modules/gui/qt4/components/open_panels.hpp | 2 +-
2 files changed, 24 insertions(+), 15 deletions(-)
diff --git a/modules/gui/qt4/components/open_panels.cpp b/modules/gui/qt4/components/open_panels.cpp
index 7b23075..853a619 100644
--- a/modules/gui/qt4/components/open_panels.cpp
+++ b/modules/gui/qt4/components/open_panels.cpp
@@ -1021,12 +1021,16 @@ void CaptureOpenPanel::initialize()
dvbc = new QRadioButton( "DVB-C" );
dvbs = new QRadioButton( "DVB-S" );
dvbt = new QRadioButton( "DVB-T" );
+ atsc = new QRadioButton( "ATSC" );
+ cqam = new QRadioButton( "Clear QAM" );
dvbt->setChecked( true );
dvbDevLayout->addWidget( dvbTypeLabel, 1, 0 );
dvbDevLayout->addWidget( dvbc, 1, 1 );
dvbDevLayout->addWidget( dvbs, 1, 2 );
dvbDevLayout->addWidget( dvbt, 1, 3 );
+ dvbDevLayout->addWidget( atsc, 1, 4 );
+ dvbDevLayout->addWidget( cqam, 1, 5 );
/* DVB Props panel */
QLabel *dvbFreqLabel =
@@ -1087,9 +1091,13 @@ void CaptureOpenPanel::initialize()
BUTTONACT( dvbs, updateButtons() );
BUTTONACT( dvbt, updateButtons() );
BUTTONACT( dvbc, updateButtons() );
+ BUTTONACT( atsc, updateButtons() );
+ BUTTONACT( cqam, updateButtons() );
BUTTONACT( dvbs, updateMRL() );
BUTTONACT( dvbt, updateMRL() );
- BUTTONACT( dvbc, updateMRL() );
+ BUTTONACT( dvbs, updateMRL() );
+ BUTTONACT( atsc, updateMRL() );
+ BUTTONACT( cqam, updateMRL() );
}
#endif
@@ -1217,10 +1225,14 @@ void CaptureOpenPanel::updateMRL()
if( dvbs->isChecked() ) mrl = "dvb-s://";
else
if( dvbt->isChecked() ) mrl = "dvb-t://";
+ else
+ if( atsc->isChecked() ) mrl = "atsc://";
+ else
+ if( cqam->isChecked() ) mrl = "cqam://";
mrl += "frequency=" + QString::number( dvbFreq->value() );
- if( dvbc->isChecked() )
+ if( dvbc->isChecked() || cqam->isChecked() )
{
unsigned qam =
dvbModBox->itemData( dvbModBox->currentIndex() ).toInt();
@@ -1231,9 +1243,9 @@ void CaptureOpenPanel::updateMRL()
}
mrl += ":srate=" + QString::number( dvbSrate->value() );
}
- else if( dvbs->isChecked() )
+ if( dvbc->isChecked() || dvbs->isChecked() )
mrl += ":srate=" + QString::number( dvbSrate->value() );
- else if( dvbt->isChecked() )
+ if( dvbt->isChecked() )
mrl += ":bandwidth=" +
QString::number( dvbBandBox->itemData(
dvbBandBox->currentIndex() ).toInt() );
@@ -1296,30 +1308,27 @@ void CaptureOpenPanel::updateButtons()
break;
#else
case DVB_DEVICE:
+ dvbSrate->hide();
+ dvbSrateLabel->hide();
+ dvbModBox->hide();
+ dvbModLabel->hide();
+ dvbBandBox->hide();
+ dvbBandLabel->hide();
+
if( dvbc->isChecked() )
{
dvbSrate->show();
dvbSrateLabel->show();
dvbModBox->show();
dvbModLabel->show();
- dvbBandBox->hide();
- dvbBandLabel->hide();
}
else if( dvbs->isChecked() )
{
dvbSrate->show();
dvbSrateLabel->show();
- dvbModBox->hide();
- dvbModLabel->hide();
- dvbBandBox->hide();
- dvbBandLabel->hide();
}
else if( dvbt->isChecked() )
{
- dvbSrate->hide();
- dvbSrateLabel->hide();
- dvbModBox->hide();
- dvbModLabel->hide();
dvbBandBox->show();
dvbBandLabel->show();
}
diff --git a/modules/gui/qt4/components/open_panels.hpp b/modules/gui/qt4/components/open_panels.hpp
index fee01c5..528b38a 100644
--- a/modules/gui/qt4/components/open_panels.hpp
+++ b/modules/gui/qt4/components/open_panels.hpp
@@ -208,7 +208,7 @@ private:
StringListConfigControl *vdevDshowW, *adevDshowW;
QLineEdit *dshowVSizeLine;
#else
- QRadioButton *dvbs, *dvbt, *dvbc;
+ QRadioButton *dvbs, *dvbt, *dvbc, *atsc, *cqam;
QLabel *dvbBandLabel, *dvbSrateLabel, *dvbModLabel;
QSpinBox *pvrFreq, *pvrBitr;
QComboBox *v4l2VideoDevice, *v4l2AudioDevice;
More information about the vlc-commits
mailing list