|
|
|
@ -127,38 +127,36 @@ KStreamRipper::~KStreamRipper()
|
|
|
|
|
void KStreamRipper::closeEvent( TQCloseEvent *e )
|
|
|
|
|
{
|
|
|
|
|
TDEConfig *appConfig = TDEGlobal::config();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
appConfig->writeEntry( "Destination", m_destEdit->text());
|
|
|
|
|
appConfig->writeEntry( "Riptime", m_timeEdit->text());
|
|
|
|
|
appConfig->writeEntry( "Command", m_tuneInEdit->text());
|
|
|
|
|
appConfig->writeEntry( "Id3Tag", m_id3Checkbox->isChecked());
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//save the listview entrys
|
|
|
|
|
|
|
|
|
|
TQStringList nameList,urlList,descList;
|
|
|
|
|
TQListViewItemIterator iter( m_streamsListView );
|
|
|
|
|
|
|
|
|
|
while( iter.current() )
|
|
|
|
|
{
|
|
|
|
|
ProcessListViewItem * ProcItem = (ProcessListViewItem*)iter.current();
|
|
|
|
|
if(ProcItem->getProcessController()->getAutomatic()) continue;
|
|
|
|
|
|
|
|
|
|
nameList.append( iter.current()->text( 0 ));
|
|
|
|
|
urlList.append( ProcItem->getProcessController()->getUrl() );
|
|
|
|
|
descList.append( ProcItem->getProcessController()->getDescription() );
|
|
|
|
|
if ( ProcItem->getProcessController()->getStatus() )
|
|
|
|
|
while( m_streamsListView->childCount() > 0)
|
|
|
|
|
{
|
|
|
|
|
ProcessListViewItem * procItem = (ProcessListViewItem*)m_streamsListView->firstChild();
|
|
|
|
|
if (!procItem->getProcessController()->getAutomatic())
|
|
|
|
|
{
|
|
|
|
|
nameList.append( procItem->text( 0 ));
|
|
|
|
|
urlList.append( procItem->getProcessController()->getUrl() );
|
|
|
|
|
descList.append( procItem->getProcessController()->getDescription() );
|
|
|
|
|
if ( procItem->getProcessController()->getStatus() )
|
|
|
|
|
{
|
|
|
|
|
ProcItem->getProcessController()->stopRip();
|
|
|
|
|
procItem->getProcessController()->stopRip();
|
|
|
|
|
}
|
|
|
|
|
++iter;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
delete procItem;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
appConfig->writeEntry( "names", nameList );
|
|
|
|
|
appConfig->writeEntry( "urls" , urlList );
|
|
|
|
|
appConfig->writeEntry( "descs", descList );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
appConfig->sync();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
e->accept();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|