Results 1 to 5 of 5

Thread: Phonon skipping two tracks

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Nov 2009
    Posts
    2
    Qt products
    Qt3 Qt4 PyQt3 PyQt4
    Platforms
    Unix/X11

    Default Phonon skipping two tracks

    I'm trying to make a media player, the main problem at the moment is that when the user presses the next button it skipps two tracks instead of one. I think this is to do with the signals so I added blockSignals(true), but it still doesn't work:
    Qt Code:
    1. void MainWindow::nextFile()
    2. {
    3.  
    4. int index = sources.indexOf(mediaObject->currentSource()) + 1;
    5.  
    6. if (sources.size() > index) {
    7. mediaObject->stop();
    8. mediaObject->clearQueue();
    9. mediaObject->blockSignals(true);
    10. index = sources.indexOf(mediaObject->currentSource()) + 1;
    11. mediaObject->setCurrentSource(sources.at(index));
    12. mediaObject->blockSignals(false);
    13. mediaObject->play();
    14. setLabelNowPlaying();
    15. }
    16. }
    To copy to clipboard, switch view to plain text mode 
    ?
    Attached Files Attached Files

Similar Threads

  1. I cannot run the phonon demos in the PXA270!Can someone help me?
    By Justin_W in forum Qt for Embedded and Mobile
    Replies: 8
    Last Post: 19th February 2010, 10:14
  2. Replies: 2
    Last Post: 24th April 2009, 12:13
  3. Problem with compiling qt on windows xp with phonon
    By junky in forum Installation and Deployment
    Replies: 3
    Last Post: 13th April 2009, 08:13
  4. Phonon in standalone app via py2app - backend plugin error
    By tory108 in forum Installation and Deployment
    Replies: 6
    Last Post: 20th February 2009, 18:36
  5. Phonon issues with DirectSound9
    By Zoltán in forum Qt Programming
    Replies: 2
    Last Post: 2nd February 2009, 02:48

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.