@ -103,7 +103,7 @@ KSCD::KSCD( TQWidget *parent, const char *name )
random_current = random_list . begin ( ) ;
cddb = new KCDDB : : Client ( ) ;
connect ( cddb , TQ T _SIGNAL( finished ( CDDB : : Result ) ) , this , TQ T _SLOT( lookupCDDBDone ( CDDB : : Result ) ) ) ;
connect ( cddb , TQ _SIGNAL( finished ( CDDB : : Result ) ) , this , TQ _SLOT( lookupCDDBDone ( CDDB : : Result ) ) ) ;
# if defined(BUILD_CDDA)
audio_systems_list
@ -124,10 +124,10 @@ KSCD::KSCD( TQWidget *parent, const char *name )
// the time slider
timeIcon - > setPixmap ( SmallIcon ( " player_time " ) ) ;
connect ( timeSlider , TQ T _SIGNAL( sliderPressed ( ) ) , TQ T _SLOT( timeSliderPressed ( ) ) ) ;
connect ( timeSlider , TQ T _SIGNAL( sliderReleased ( ) ) , TQ T _SLOT( timeSliderReleased ( ) ) ) ;
connect ( timeSlider , TQ T _SIGNAL( sliderMoved ( int ) ) , TQ T _SLOT( timeSliderMoved ( int ) ) ) ;
connect ( timeSlider , TQ T _SIGNAL( valueChanged ( int ) ) , TQ T _SLOT( jumpToTime ( int ) ) ) ;
connect ( timeSlider , TQ _SIGNAL( sliderPressed ( ) ) , TQ _SLOT( timeSliderPressed ( ) ) ) ;
connect ( timeSlider , TQ _SIGNAL( sliderReleased ( ) ) , TQ _SLOT( timeSliderReleased ( ) ) ) ;
connect ( timeSlider , TQ _SIGNAL( sliderMoved ( int ) ) , TQ _SLOT( timeSliderMoved ( int ) ) ) ;
connect ( timeSlider , TQ _SIGNAL( valueChanged ( int ) ) , TQ _SLOT( jumpToTime ( int ) ) ) ;
// the volume slider
volumeIcon - > setPixmap ( SmallIcon ( " player_volume " ) ) ;
@ -135,33 +135,33 @@ KSCD::KSCD( TQWidget *parent, const char *name )
TQString str ;
str = TQString : : fromUtf8 ( TQCString ( ) . sprintf ( i18n ( " Vol: %02d%% " ) . utf8 ( ) , Prefs : : volume ( ) ) ) ;
volumelabel - > setText ( str ) ;
connect ( volumeSlider , TQ T _SIGNAL( valueChanged ( int ) ) , TQ T _SLOT( volChanged ( int ) ) ) ;
connect ( volumeSlider , TQ _SIGNAL( valueChanged ( int ) ) , TQ _SLOT( volChanged ( int ) ) ) ;
/* FIXME check for return value */
setDevicePaths ( /*Prefs::cdDevice(), Prefs::audioSystem(), Prefs::audioDevice()*/ ) ;
connect ( m_cd , TQ T _SIGNAL( trackPlaying ( unsigned , unsigned ) ) , this , TQ T _SLOT( trackUpdate ( unsigned , unsigned ) ) ) ;
connect ( m_cd , TQ T _SIGNAL( trackPaused ( unsigned , unsigned ) ) , this , TQ T _SLOT( trackUpdate ( unsigned , unsigned ) ) ) ;
connect ( m_cd , TQ T _SIGNAL( trackChanged ( unsigned , unsigned ) ) , this , TQ T _SLOT( trackChanged ( unsigned , unsigned ) ) ) ;
connect ( m_cd , TQ T _SIGNAL( discStopped ( ) ) , this , TQ T _SLOT( discStopped ( ) ) ) ;
connect ( m_cd , TQ T _SIGNAL( discChanged ( unsigned ) ) , this , TQ T _SLOT( discChanged ( unsigned ) ) ) ;
connect ( & queryledtimer , TQ T _SIGNAL( timeout ( ) ) , TQ T _SLOT( togglequeryled ( ) ) ) ;
connect ( & titlelabeltimer , TQ T _SIGNAL( timeout ( ) ) , TQ T _SLOT( titlelabeltimeout ( ) ) ) ;
connect ( & cycletimer , TQ T _SIGNAL( timeout ( ) ) , TQ T _SLOT( cycletimeout ( ) ) ) ;
connect ( & jumpTrackTimer , TQ T _SIGNAL( timeout ( ) ) , TQ T _SLOT( jumpTracks ( ) ) ) ;
connect ( m_cd , TQ _SIGNAL( trackPlaying ( unsigned , unsigned ) ) , this , TQ _SLOT( trackUpdate ( unsigned , unsigned ) ) ) ;
connect ( m_cd , TQ _SIGNAL( trackPaused ( unsigned , unsigned ) ) , this , TQ _SLOT( trackUpdate ( unsigned , unsigned ) ) ) ;
connect ( m_cd , TQ _SIGNAL( trackChanged ( unsigned , unsigned ) ) , this , TQ _SLOT( trackChanged ( unsigned , unsigned ) ) ) ;
connect ( m_cd , TQ _SIGNAL( discStopped ( ) ) , this , TQ _SLOT( discStopped ( ) ) ) ;
connect ( m_cd , TQ _SIGNAL( discChanged ( unsigned ) ) , this , TQ _SLOT( discChanged ( unsigned ) ) ) ;
connect ( & queryledtimer , TQ _SIGNAL( timeout ( ) ) , TQ _SLOT( togglequeryled ( ) ) ) ;
connect ( & titlelabeltimer , TQ _SIGNAL( timeout ( ) ) , TQ _SLOT( titlelabeltimeout ( ) ) ) ;
connect ( & cycletimer , TQ _SIGNAL( timeout ( ) ) , TQ _SLOT( cycletimeout ( ) ) ) ;
connect ( & jumpTrackTimer , TQ _SIGNAL( timeout ( ) ) , TQ _SLOT( jumpTracks ( ) ) ) ;
/*
these are always connected in base class
connect ( playPB , TQ T _SIGNAL( clicked ( ) ) , TQ T _SLOT( playClicked ( ) ) ) ;
connect ( nextPB , TQ T _SIGNAL( clicked ( ) ) , TQ T _SLOT( nextClicked ( ) ) ) ;
connect ( prevPB , TQ T _SIGNAL( clicked ( ) ) , TQ T _SLOT( prevClicked ( ) ) ) ;
connect ( stopPB , TQ T _SIGNAL( clicked ( ) ) , TQ T _SLOT( stopClicked ( ) ) ) ;
connect ( ejectPB , TQ T _SIGNAL( clicked ( ) ) , TQ T _SLOT( ejectClicked ( ) ) ) ;
connect ( playPB , TQ _SIGNAL( clicked ( ) ) , TQ _SLOT( playClicked ( ) ) ) ;
connect ( nextPB , TQ _SIGNAL( clicked ( ) ) , TQ _SLOT( nextClicked ( ) ) ) ;
connect ( prevPB , TQ _SIGNAL( clicked ( ) ) , TQ _SLOT( prevClicked ( ) ) ) ;
connect ( stopPB , TQ _SIGNAL( clicked ( ) ) , TQ _SLOT( stopClicked ( ) ) ) ;
connect ( ejectPB , TQ _SIGNAL( clicked ( ) ) , TQ _SLOT( ejectClicked ( ) ) ) ;
*/
connect ( repeatPB , TQ T _SIGNAL( clicked ( ) ) , TQ T _SLOT( loopClicked ( ) ) ) ;
connect ( songListCB , TQ T _SIGNAL( activated ( int ) ) , TQ T _SLOT( trackSelected ( int ) ) ) ;
connect ( shufflePB , TQ T _SIGNAL( clicked ( ) ) , TQ T _SLOT( randomSelected ( ) ) ) ;
connect ( cddbPB , TQ T _SIGNAL( clicked ( ) ) , TQ T _SLOT( CDDialogSelected ( ) ) ) ;
connect ( kapp , TQ T _SIGNAL( tdedisplayPaletteChanged ( ) ) , this , TQ T _SLOT( setColors ( ) ) ) ;
connect ( kapp , TQ T _SIGNAL( iconChanged ( int ) ) , this , TQ T _SLOT( setIcons ( ) ) ) ;
connect ( repeatPB , TQ _SIGNAL( clicked ( ) ) , TQ _SLOT( loopClicked ( ) ) ) ;
connect ( songListCB , TQ _SIGNAL( activated ( int ) ) , TQ _SLOT( trackSelected ( int ) ) ) ;
connect ( shufflePB , TQ _SIGNAL( clicked ( ) ) , TQ _SLOT( randomSelected ( ) ) ) ;
connect ( cddbPB , TQ _SIGNAL( clicked ( ) ) , TQ _SLOT( CDDialogSelected ( ) ) ) ;
connect ( kapp , TQ _SIGNAL( tdedisplayPaletteChanged ( ) ) , this , TQ _SLOT( setColors ( ) ) ) ;
connect ( kapp , TQ _SIGNAL( iconChanged ( int ) ) , this , TQ _SLOT( setIcons ( ) ) ) ;
TQToolTip : : remove ( songListCB ) ;
TQToolTip : : add ( songListCB , i18n ( " Track list " ) ) ;
@ -170,24 +170,24 @@ KSCD::KSCD( TQWidget *parent, const char *name )
m_actions = new TDEActionCollection ( this ) ;
TDEAction * action ;
action = new TDEAction ( i18n ( " Play/Pause " ) , Key_P , this , TQ T _SLOT( playClicked ( ) ) , m_actions , " Play/Pause " ) ;
action = new TDEAction ( i18n ( " Stop " ) , Key_S , this , TQ T _SLOT( stopClicked ( ) ) , m_actions , " Stop " ) ;
action = new TDEAction ( i18n ( " Previous " ) , Key_B , this , TQ T _SLOT( prevClicked ( ) ) , m_actions , " Previous " ) ;
action = new TDEAction ( i18n ( " Next " ) , Key_N , this , TQ T _SLOT( nextClicked ( ) ) , m_actions , " Next " ) ;
action = KStdAction : : quit ( this , TQ T _SLOT( quitClicked ( ) ) , m_actions ) ;
action = KStdAction : : keyBindings ( this , TQ T _SLOT( configureKeys ( ) ) , m_actions , " options_configure_shortcuts " ) ;
action = KStdAction : : keyBindings ( this , TQ T _SLOT( configureGlobalKeys ( ) ) , m_actions , " options_configure_globals " ) ;
action = KStdAction : : preferences ( this , TQ T _SLOT( showConfig ( ) ) , m_actions ) ;
action = new TDEAction ( i18n ( " Loop " ) , Key_L , this , TQ T _SLOT( loopClicked ( ) ) , m_actions , " Loop " ) ;
action = new TDEAction ( i18n ( " Eject " ) , CTRL + Key_E , this , TQ T _SLOT( ejectClicked ( ) ) , m_actions , " Eject " ) ;
action = new TDEAction ( i18n ( " Increase Volume " ) , Key_Plus , this , TQ T _SLOT( incVolume ( ) ) , m_actions , " IncVolume " ) ;
action = new TDEAction ( i18n ( " Play/Pause " ) , Key_P , this , TQ _SLOT( playClicked ( ) ) , m_actions , " Play/Pause " ) ;
action = new TDEAction ( i18n ( " Stop " ) , Key_S , this , TQ _SLOT( stopClicked ( ) ) , m_actions , " Stop " ) ;
action = new TDEAction ( i18n ( " Previous " ) , Key_B , this , TQ _SLOT( prevClicked ( ) ) , m_actions , " Previous " ) ;
action = new TDEAction ( i18n ( " Next " ) , Key_N , this , TQ _SLOT( nextClicked ( ) ) , m_actions , " Next " ) ;
action = KStdAction : : quit ( this , TQ _SLOT( quitClicked ( ) ) , m_actions ) ;
action = KStdAction : : keyBindings ( this , TQ _SLOT( configureKeys ( ) ) , m_actions , " options_configure_shortcuts " ) ;
action = KStdAction : : keyBindings ( this , TQ _SLOT( configureGlobalKeys ( ) ) , m_actions , " options_configure_globals " ) ;
action = KStdAction : : preferences ( this , TQ _SLOT( showConfig ( ) ) , m_actions ) ;
action = new TDEAction ( i18n ( " Loop " ) , Key_L , this , TQ _SLOT( loopClicked ( ) ) , m_actions , " Loop " ) ;
action = new TDEAction ( i18n ( " Eject " ) , CTRL + Key_E , this , TQ _SLOT( ejectClicked ( ) ) , m_actions , " Eject " ) ;
action = new TDEAction ( i18n ( " Increase Volume " ) , Key_Plus , this , TQ _SLOT( incVolume ( ) ) , m_actions , " IncVolume " ) ;
TDEShortcut increaseVolume = action - > shortcut ( ) ;
increaseVolume . append ( KKey ( Key_Equal ) ) ;
action - > setShortcut ( increaseVolume ) ;
action = new TDEAction ( i18n ( " Decrease Volume " ) , Key_Minus , this , TQ T _SLOT( decVolume ( ) ) , m_actions , " DecVolume " ) ;
action = new TDEAction ( i18n ( " Options " ) , CTRL + Key_T , this , TQ T _SLOT( showConfig ( ) ) , m_actions , " Options " ) ;
action = new TDEAction ( i18n ( " Shuffle " ) , Key_R , this , TQ T _SLOT( randomSelected ( ) ) , m_actions , " Shuffle " ) ;
action = new TDEAction ( i18n ( " CDDB " ) , CTRL + Key_D , this , TQ T _SLOT( CDDialogSelected ( ) ) , m_actions , " CDDB " ) ;
action = new TDEAction ( i18n ( " Decrease Volume " ) , Key_Minus , this , TQ _SLOT( decVolume ( ) ) , m_actions , " DecVolume " ) ;
action = new TDEAction ( i18n ( " Options " ) , CTRL + Key_T , this , TQ _SLOT( showConfig ( ) ) , m_actions , " Options " ) ;
action = new TDEAction ( i18n ( " Shuffle " ) , Key_R , this , TQ _SLOT( randomSelected ( ) ) , m_actions , " Shuffle " ) ;
action = new TDEAction ( i18n ( " CDDB " ) , CTRL + Key_D , this , TQ _SLOT( CDDialogSelected ( ) ) , m_actions , " CDDB " ) ;
m_actions - > readShortcutSettings ( " Shortcuts " ) ;
@ -232,20 +232,20 @@ void KSCD::initGlobalShortcuts() {
//Definition of global shortcuts is based on 'local' shortcuts which follow
//the WIN key.
m_globalAccel - > insert ( " Next " , i18n ( " Next " ) , 0 , KKey ( " WIN+N " ) , KKey ( " WIN+Right " ) ,
this , TQ T _SLOT( nextClicked ( ) ) ) ;
this , TQ _SLOT( nextClicked ( ) ) ) ;
//NOTE: WIN+B collidates with amarok's default global shortcut.
m_globalAccel - > insert ( " Previous " , i18n ( " Previous " ) , 0 , KKey ( " WIN+B " ) , KKey ( " WIN+Left " ) ,
this , TQ T _SLOT( prevClicked ( ) ) ) ;
this , TQ _SLOT( prevClicked ( ) ) ) ;
m_globalAccel - > insert ( " Play/Pause " , i18n ( " Play/Pause " ) , 0 , KKey ( " WIN+P " ) , 0 ,
this , TQ T _SLOT( playClicked ( ) ) ) ;
this , TQ _SLOT( playClicked ( ) ) ) ;
m_globalAccel - > insert ( " Stop " , i18n ( " Stop " ) , 0 , KKey ( " WIN+S " ) , 0 ,
this , TQ T _SLOT( stopClicked ( ) ) ) ;
this , TQ _SLOT( stopClicked ( ) ) ) ;
m_globalAccel - > insert ( " IncVolume " , i18n ( " Increase Volume " ) , 0 , KKey ( " WIN+Plus " ) , KKey ( " WIN+Up " ) ,
this , TQ T _SLOT( incVolume ( ) ) ) ;
this , TQ _SLOT( incVolume ( ) ) ) ;
m_globalAccel - > insert ( " DecVolume " , i18n ( " Decrease Volume " ) , 0 , KKey ( " WIN+Minus " ) , KKey ( " WIN+Down " ) ,
this , TQ T _SLOT( decVolume ( ) ) ) ;
this , TQ _SLOT( decVolume ( ) ) ) ;
m_globalAccel - > insert ( " Shuffle " , i18n ( " Shuffle " ) , 0 , KKey ( " WIN+R " ) , 0 ,
this , TQ T _SLOT( incVolume ( ) ) ) ;
this , TQ _SLOT( incVolume ( ) ) ) ;
m_globalAccel - > setConfigGroup ( " GlobalShortcuts " ) ;
m_globalAccel - > readSettings ( kapp - > config ( ) ) ;
@ -312,7 +312,7 @@ void KSCD::drawPanel()
trackTimeLED [ u ] - > setLEDoffColor ( Prefs : : backColor ( ) ) ;
trackTimeLED [ u ] - > setLEDColor ( Prefs : : ledColor ( ) , Prefs : : backColor ( ) ) ;
trackTimeLED [ u ] - > setGeometry ( 2 + u * 18 , D , 23 , 30 ) ;
connect ( trackTimeLED [ u ] , TQ T _SIGNAL( clicked ( ) ) , this , TQ T _SLOT( cycleplaytimemode ( ) ) ) ;
connect ( trackTimeLED [ u ] , TQ _SIGNAL( clicked ( ) ) , this , TQ _SLOT( cycleplaytimemode ( ) ) ) ;
}
setLEDs ( - 1 ) ;
@ -369,7 +369,7 @@ void KSCD::setupPopups()
mainPopup - > insertItem ( i18n ( " Artist Information " ) , infoPopup ) ;
connect ( infoPopup , TQ T _SIGNAL( activated ( int ) ) , TQ T _SLOT( information ( int ) ) ) ;
connect ( infoPopup , TQ _SIGNAL( activated ( int ) ) , TQ _SLOT( information ( int ) ) ) ;
KHelpMenu * helpMenu = new KHelpMenu ( this , TDEGlobal : : instance ( ) - > aboutData ( ) , false ) ;
mainPopup - > insertItem ( SmallIcon ( " help " ) , i18n ( " &Help " ) , helpMenu - > menu ( ) ) ;
@ -756,16 +756,16 @@ void KSCD::showConfig()
cfg - > readConfig ( ) ;
configDialog - > addPage ( m , cfg , TQString ( " CDDB " ) , " application-x-cda " , i18n ( " Configure Fetching Items " ) ) ;
connect ( configDialog , TQ T _SIGNAL( okClicked ( ) ) , m , TQ T _SLOT( save ( ) ) ) ;
connect ( configDialog , TQ T _SIGNAL( applyClicked ( ) ) , m , TQ T _SLOT( save ( ) ) ) ;
connect ( configDialog , TQ T _SIGNAL( defaultClicked ( ) ) , m , TQ T _SLOT( defaults ( ) ) ) ;
connect ( configDialog , TQ _SIGNAL( okClicked ( ) ) , m , TQ _SLOT( save ( ) ) ) ;
connect ( configDialog , TQ _SIGNAL( applyClicked ( ) ) , m , TQ _SLOT( save ( ) ) ) ;
connect ( configDialog , TQ _SIGNAL( defaultClicked ( ) ) , m , TQ _SLOT( defaults ( ) ) ) ;
}
}
}
updateConfigDialog ( confWidget ) ;
connect ( configDialog , TQ T _SIGNAL( settingsChanged ( ) ) , this , TQ T _SLOT( configDone ( ) ) ) ;
connect ( configDialog , TQ _SIGNAL( settingsChanged ( ) ) , this , TQ _SLOT( configDone ( ) ) ) ;
configDialog - > show ( ) ;
} // showConfig()
@ -814,14 +814,14 @@ void KSCD::setDocking(bool dock)
if ( ! m_dockWidget )
{
m_dockWidget = new DockWidget ( this , " dockw " ) ;
connect ( m_dockWidget , TQ T _SIGNAL( quitSelected ( ) ) , this , TQ T _SLOT( quitClicked ( ) ) ) ;
connect ( m_dockWidget , TQ _SIGNAL( quitSelected ( ) ) , this , TQ _SLOT( quitClicked ( ) ) ) ;
}
m_dockWidget - > show ( ) ;
connect ( this , TQ T _SIGNAL( trackChanged ( const TQString & ) ) ,
m_dockWidget , TQ T _SLOT( setToolTip ( const TQString & ) ) ) ;
connect ( this , TQ T _SIGNAL( trackChanged ( const TQString & ) ) ,
m_dockWidget , TQ T _SLOT( createPopup ( const TQString & ) ) ) ;
connect ( this , TQ _SIGNAL( trackChanged ( const TQString & ) ) ,
m_dockWidget , TQ _SLOT( setToolTip ( const TQString & ) ) ) ;
connect ( this , TQ _SIGNAL( trackChanged ( const TQString & ) ) ,
m_dockWidget , TQ _SLOT( createPopup ( const TQString & ) ) ) ;
}
else
{
@ -1155,11 +1155,11 @@ void KSCD::CDDialogSelected()
cddialog = new CDDBDlg ( this ) ;
cddialog - > setData ( cddbInfo , m_cd - > discSignature ( ) , playlist ) ;
connect ( cddialog , TQ T _SIGNAL( cddbQuery ( ) ) , TQ T _SLOT( lookupCDDB ( ) ) ) ;
connect ( cddialog , TQ T _SIGNAL( newCDInfoStored ( KCDDB : : CDInfo ) ) ,
TQ T _SLOT( setCDInfo ( KCDDB : : CDInfo ) ) ) ;
connect ( cddialog , TQ T _SIGNAL( finished ( ) ) , TQ T _SLOT( CDDialogDone ( ) ) ) ;
connect ( cddialog , TQ T _SIGNAL( play ( int ) ) , TQ T _SLOT( trackSelected ( int ) ) ) ;
connect ( cddialog , TQ _SIGNAL( cddbQuery ( ) ) , TQ _SLOT( lookupCDDB ( ) ) ) ;
connect ( cddialog , TQ _SIGNAL( newCDInfoStored ( KCDDB : : CDInfo ) ) ,
TQ _SLOT( setCDInfo ( KCDDB : : CDInfo ) ) ) ;
connect ( cddialog , TQ _SIGNAL( finished ( ) ) , TQ _SLOT( CDDialogDone ( ) ) ) ;
connect ( cddialog , TQ _SIGNAL( play ( int ) ) , TQ _SLOT( trackSelected ( int ) ) ) ;
}
cddialog - > show ( ) ;