mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-10-16 15:41:13 +02:00
2020-08-11 Fred Gleason <fredg@paravelsystems.com>
* Dropped the 'ENCODERS', 'ENCODER_BITRATES', 'ENCODER_BITRATES' and 'ENCODER_CHANNELS' tables from the database. * Incremented the database version to 331. * Removed the 'RDSettings::customCommandLine()', 'RDSettings::setCustomCommandLine()' and ' RDSettings::resolvedCustomCommandLine()' methods. Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
@@ -206,8 +206,9 @@ ListCasts::ListCasts(unsigned feed_id,bool is_super,QWidget *parent)
|
||||
connect(list_close_button,SIGNAL(clicked()),this,SLOT(closeData()));
|
||||
|
||||
RefreshList();
|
||||
GetEncoderId();
|
||||
|
||||
connect(rda->ripc(),SIGNAL(userChanged()),this,SLOT(userChangedData()));
|
||||
|
||||
userChangedData();
|
||||
}
|
||||
|
||||
@@ -440,10 +441,8 @@ void ListCasts::userChangedData()
|
||||
{
|
||||
bool is_superfeed=list_feed->isSuperfeed();
|
||||
|
||||
list_cart_button->setEnabled(rda->user()->addPodcast()&&
|
||||
(list_encoder_id>=0)&&(!is_superfeed));
|
||||
list_file_button->setEnabled(rda->user()->addPodcast()&&
|
||||
(list_encoder_id>=0)&&(!is_superfeed));
|
||||
list_cart_button->setEnabled(rda->user()->addPodcast()&&(!is_superfeed));
|
||||
list_file_button->setEnabled(rda->user()->addPodcast()&&(!is_superfeed));
|
||||
list_edit_button->setEnabled(rda->user()->editPodcast()&&(!is_superfeed));
|
||||
list_delete_button->
|
||||
setEnabled(rda->user()->deletePodcast()&&(!is_superfeed));
|
||||
@@ -640,32 +639,3 @@ void ListCasts::RefreshItem(RDListViewItem *item)
|
||||
}
|
||||
delete q;
|
||||
}
|
||||
|
||||
|
||||
void ListCasts::GetEncoderId()
|
||||
{
|
||||
QString sql;
|
||||
RDSqlQuery *q;
|
||||
|
||||
list_encoder_id=-1;
|
||||
RDFeed *feed=new RDFeed(list_feed_id,rda->config());
|
||||
int format=feed->uploadFormat();
|
||||
delete feed;
|
||||
if((format>0)&&(format<100)) { // Built-in format
|
||||
list_encoder_id=format;
|
||||
return;
|
||||
}
|
||||
sql=QString().sprintf("select NAME from ENCODERS where ID=%d",format);
|
||||
q=new RDSqlQuery(sql);
|
||||
if(q->first()) {
|
||||
sql=QString("select ID from ENCODERS where ")+
|
||||
"(NAME=\""+RDEscapeString(q->value(0).toString())+"\")&&"+
|
||||
"(STATION_NAME=\""+RDEscapeString(rda->station()->name())+"\")";
|
||||
delete q;
|
||||
q=new RDSqlQuery(sql);
|
||||
if(q->first()) {
|
||||
list_encoder_id=q->value(0).toInt();
|
||||
}
|
||||
}
|
||||
delete q;
|
||||
}
|
||||
|
Reference in New Issue
Block a user