[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    kdemultimedia/kscd
From:       Shaheed Haque <srhaque () iee ! org>
Date:       2005-03-29 4:42:52
Message-ID: 20050329044252.831843C9 () office ! kde ! org
[Download RAW message or body]

CVS commit by shaheed: 

1. Richard confirmed that CDDB lookup failures work gracefully now.
2. Eliminate hack for disc change detection: seems fixed (probably by
initialisation fixes).


  M +4 -18     kscd.cpp   1.308


--- kdemultimedia/kscd/kscd.cpp  #1.307:1.308
@@ -103,4 +103,5 @@ KSCD::KSCD( QWidget *parent, const char 
 
   cddb = new KCDDB::Client();
+  connect(cddb, SIGNAL(finished(CDDB::Result)), this, SLOT(lookupCDDBDone(CDDB::Result)));
 
 #if defined(BUILD_CDDA)
@@ -1105,12 +1106,5 @@ void KSCD::lookupCDDB()
     cddb->config().reparse();
     cddb->setBlockingMode(false);
-    connect(cddb, SIGNAL(finished(CDDB::Result)), this, SLOT(lookupCDDBDone(CDDB::Result)));
-
-    // FIXME Should be enabled again when it doesn't go into an infinite loop
-    // when the disc is played and no entry is found
-//    QValueList<unsigned> messedUp = m_cd->cddbSignature();
-//    messedUp.append(0);
-//    cddb->lookup(messedUp);
-//    cddb->lookup(m_cd->cddbSignature());
+    cddb->lookup(m_cd->cddbSignature());
 } // lookupCDDB
 
@@ -1248,14 +1242,6 @@ bool KSCD::playing()
 }
 
-void KSCD::trackUpdate(unsigned track, unsigned trackPosition)
+void KSCD::trackUpdate(unsigned /*track*/, unsigned trackPosition)
 {
-    // This is a hack. Sometimes, discChanged does not get called on startup even
-    // though signals are supposedly delivered synchronously by KCompactDisc.
-    if (songListCB->count() == 0)
-    {
-        discChanged(m_cd->discId());
-        trackChanged(track, m_cd->trackLength());
-    }
-
     unsigned tmp;
 
@@ -1281,5 +1267,5 @@ void KSCD::trackUpdate(unsigned track, u
     setLEDs(tmp);
     timeSlider->blockSignals(true);
-    timeSlider->setValue(m_cd->trackPosition());
+    timeSlider->setValue(trackPosition);
     timeSlider->blockSignals(false);
 }


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic