|
|
@ -64,13 +64,13 @@ KStreamRipper::KStreamRipper( TQWidget* parent, const char* name )
|
|
|
|
|
|
|
|
|
|
|
|
// Create context menu
|
|
|
|
// Create context menu
|
|
|
|
contextMenu = new TQPopupMenu( m_streamsListView );
|
|
|
|
contextMenu = new TQPopupMenu( m_streamsListView );
|
|
|
|
contextMenu->insertItem( i18n("&Add Stream"), this, TQT_SLOT(addStreamButtonClicked()), CTRL+Key_A );
|
|
|
|
contextMenu->insertItem( i18n("&Add Stream"), this, TQ_SLOT(addStreamButtonClicked()), CTRL+Key_A );
|
|
|
|
contextMenu->insertItem( i18n("&Edit Stream"), this, TQT_SLOT(editStreamButtonClicked()), CTRL+Key_E );
|
|
|
|
contextMenu->insertItem( i18n("&Edit Stream"), this, TQ_SLOT(editStreamButtonClicked()), CTRL+Key_E );
|
|
|
|
contextMenu->insertItem( i18n("&Delete Stream"), this, TQT_SLOT(deleteStreamButtonClicked()), Key_Delete );
|
|
|
|
contextMenu->insertItem( i18n("&Delete Stream"), this, TQ_SLOT(deleteStreamButtonClicked()), Key_Delete );
|
|
|
|
contextMenu->insertSeparator();
|
|
|
|
contextMenu->insertSeparator();
|
|
|
|
contextMenu->insertItem( i18n("&Rip Stream"), this, TQT_SLOT(ripButtonClicked()), CTRL+Key_R, 2 );
|
|
|
|
contextMenu->insertItem( i18n("&Rip Stream"), this, TQ_SLOT(ripButtonClicked()), CTRL+Key_R, 2 );
|
|
|
|
contextMenu->insertItem( i18n("&Stop Rip"), this, TQT_SLOT(stopRipButtonClicked()), CTRL+Key_S, 3 );
|
|
|
|
contextMenu->insertItem( i18n("&Stop Rip"), this, TQ_SLOT(stopRipButtonClicked()), CTRL+Key_S, 3 );
|
|
|
|
contextMenu->insertItem( i18n("&Tune in"), this, TQT_SLOT(tuneInButtonClicked()), CTRL+Key_T );
|
|
|
|
contextMenu->insertItem( i18n("&Tune in"), this, TQ_SLOT(tuneInButtonClicked()), CTRL+Key_T );
|
|
|
|
|
|
|
|
|
|
|
|
//app config
|
|
|
|
//app config
|
|
|
|
TDEConfig *appConfig = TDEGlobal::config();
|
|
|
|
TDEConfig *appConfig = TDEGlobal::config();
|
|
|
@ -102,34 +102,34 @@ KStreamRipper::KStreamRipper( TQWidget* parent, const char* name )
|
|
|
|
{
|
|
|
|
{
|
|
|
|
pc->setDescription( descList[idx] );
|
|
|
|
pc->setDescription( descList[idx] );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
connect(pc, TQT_SIGNAL(stopRipSignal(ProcessController*)), this, TQT_SLOT(ripStopped(ProcessController*)));
|
|
|
|
connect(pc, TQ_SIGNAL(stopRipSignal(ProcessController*)), this, TQ_SLOT(ripStopped(ProcessController*)));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
//CONNECTS
|
|
|
|
//CONNECTS
|
|
|
|
|
|
|
|
|
|
|
|
//clicks
|
|
|
|
//clicks
|
|
|
|
connect(m_addStreamButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(addStreamButtonClicked()));
|
|
|
|
connect(m_addStreamButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(addStreamButtonClicked()));
|
|
|
|
connect(m_editStreamButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(editStreamButtonClicked()));
|
|
|
|
connect(m_editStreamButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(editStreamButtonClicked()));
|
|
|
|
connect(m_deleteStreamButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(deleteStreamButtonClicked()));
|
|
|
|
connect(m_deleteStreamButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(deleteStreamButtonClicked()));
|
|
|
|
connect(m_tuneInButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(tuneInButtonClicked()));
|
|
|
|
connect(m_tuneInButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(tuneInButtonClicked()));
|
|
|
|
connect(m_ripButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(ripButtonClicked()));
|
|
|
|
connect(m_ripButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(ripButtonClicked()));
|
|
|
|
connect(m_stopRipButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(stopRipButtonClicked()));
|
|
|
|
connect(m_stopRipButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(stopRipButtonClicked()));
|
|
|
|
connect(m_browseButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(browseButtonClicked()));
|
|
|
|
connect(m_browseButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(browseButtonClicked()));
|
|
|
|
connect(m_helpButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(helpButtonClicked()));
|
|
|
|
connect(m_helpButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(helpButtonClicked()));
|
|
|
|
connect(m_aboutButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(aboutButtonClicked()));
|
|
|
|
connect(m_aboutButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(aboutButtonClicked()));
|
|
|
|
connect(m_quitButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(quitButtonClicked()));
|
|
|
|
connect(m_quitButton, TQ_SIGNAL(clicked()), this, TQ_SLOT(quitButtonClicked()));
|
|
|
|
connect(m_streamsListView, TQT_SIGNAL( contextMenuRequested( TQListViewItem *, const TQPoint& , int ) ),
|
|
|
|
connect(m_streamsListView, TQ_SIGNAL( contextMenuRequested( TQListViewItem *, const TQPoint& , int ) ),
|
|
|
|
this, TQT_SLOT( slotContextMenu( TQListViewItem *, const TQPoint &, int ) ) );
|
|
|
|
this, TQ_SLOT( slotContextMenu( TQListViewItem *, const TQPoint &, int ) ) );
|
|
|
|
|
|
|
|
|
|
|
|
//other
|
|
|
|
//other
|
|
|
|
connect( m_streamsListView, TQT_SIGNAL(selectionChanged()), this, TQT_SLOT( selectedNewListItem()) );
|
|
|
|
connect( m_streamsListView, TQ_SIGNAL(selectionChanged()), this, TQ_SLOT( selectedNewListItem()) );
|
|
|
|
|
|
|
|
|
|
|
|
// zeroconf
|
|
|
|
// zeroconf
|
|
|
|
#if KDE_IS_VERSION(3,3,90)
|
|
|
|
#if KDE_IS_VERSION(3,3,90)
|
|
|
|
connect(&m_browser, TQT_SIGNAL(serviceAdded(DNSSD::RemoteService::Ptr)), this,
|
|
|
|
connect(&m_browser, TQ_SIGNAL(serviceAdded(DNSSD::RemoteService::Ptr)), this,
|
|
|
|
TQT_SLOT(serviceAdded(DNSSD::RemoteService::Ptr)));
|
|
|
|
TQ_SLOT(serviceAdded(DNSSD::RemoteService::Ptr)));
|
|
|
|
connect(&m_browser, TQT_SIGNAL(serviceRemoved(DNSSD::RemoteService::Ptr)), this,
|
|
|
|
connect(&m_browser, TQ_SIGNAL(serviceRemoved(DNSSD::RemoteService::Ptr)), this,
|
|
|
|
TQT_SLOT(serviceRemoved(DNSSD::RemoteService::Ptr)));
|
|
|
|
TQ_SLOT(serviceRemoved(DNSSD::RemoteService::Ptr)));
|
|
|
|
m_browser.startBrowse();
|
|
|
|
m_browser.startBrowse();
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -183,7 +183,7 @@ void KStreamRipper::closeEvent( TQCloseEvent *e )
|
|
|
|
void KStreamRipper::addStreamButtonClicked()
|
|
|
|
void KStreamRipper::addStreamButtonClicked()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
StreamPropertiesDlg *dlg = new StreamPropertiesDlg(this);
|
|
|
|
StreamPropertiesDlg *dlg = new StreamPropertiesDlg(this);
|
|
|
|
connect( dlg, TQT_SIGNAL( finished( StreamPropertiesDlg* )), this, TQT_SLOT( addStreamFinished( StreamPropertiesDlg* )) );
|
|
|
|
connect( dlg, TQ_SIGNAL( finished( StreamPropertiesDlg* )), this, TQ_SLOT( addStreamFinished( StreamPropertiesDlg* )) );
|
|
|
|
dlg->setCaption("Add Stream...");
|
|
|
|
dlg->setCaption("Add Stream...");
|
|
|
|
dlg->show();
|
|
|
|
dlg->show();
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -192,7 +192,7 @@ void KStreamRipper::editStreamButtonClicked()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
ProcessListViewItem *ProcItem = (ProcessListViewItem*)m_streamsListView->currentItem();
|
|
|
|
ProcessListViewItem *ProcItem = (ProcessListViewItem*)m_streamsListView->currentItem();
|
|
|
|
StreamPropertiesDlg *dlg = new StreamPropertiesDlg(this);
|
|
|
|
StreamPropertiesDlg *dlg = new StreamPropertiesDlg(this);
|
|
|
|
connect( dlg, TQT_SIGNAL( finished( StreamPropertiesDlg* )), this, TQT_SLOT( editStreamFinished( StreamPropertiesDlg* )) );
|
|
|
|
connect( dlg, TQ_SIGNAL( finished( StreamPropertiesDlg* )), this, TQ_SLOT( editStreamFinished( StreamPropertiesDlg* )) );
|
|
|
|
dlg->setCaption("Edit Stream");
|
|
|
|
dlg->setCaption("Edit Stream");
|
|
|
|
dlg->d_nameEdit->setText(ProcItem->text(0));
|
|
|
|
dlg->d_nameEdit->setText(ProcItem->text(0));
|
|
|
|
dlg->d_urlEdit->setText(ProcItem->getProcessController()->getUrl());
|
|
|
|
dlg->d_urlEdit->setText(ProcItem->getProcessController()->getUrl());
|
|
|
@ -362,7 +362,7 @@ void KStreamRipper::addStreamFinished( StreamPropertiesDlg *e )
|
|
|
|
ProcessController *pc = procItem->getProcessController();
|
|
|
|
ProcessController *pc = procItem->getProcessController();
|
|
|
|
pc->setUrl( e->d_urlEdit->text() );
|
|
|
|
pc->setUrl( e->d_urlEdit->text() );
|
|
|
|
pc->setDescription( e->d_descEdit->text() );
|
|
|
|
pc->setDescription( e->d_descEdit->text() );
|
|
|
|
connect(pc, TQT_SIGNAL(stopRipSignal(ProcessController*)), this, TQT_SLOT(ripStopped(ProcessController*)));
|
|
|
|
connect(pc, TQ_SIGNAL(stopRipSignal(ProcessController*)), this, TQ_SLOT(ripStopped(ProcessController*)));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void KStreamRipper::editStreamFinished( StreamPropertiesDlg *e )
|
|
|
|
void KStreamRipper::editStreamFinished( StreamPropertiesDlg *e )
|
|
|
|