summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--noncore/multimedia/opieplayer2/playlistwidget.cpp28
1 files changed, 20 insertions, 8 deletions
diff --git a/noncore/multimedia/opieplayer2/playlistwidget.cpp b/noncore/multimedia/opieplayer2/playlistwidget.cpp
index 16467c0..ccf654f 100644
--- a/noncore/multimedia/opieplayer2/playlistwidget.cpp
+++ b/noncore/multimedia/opieplayer2/playlistwidget.cpp
@@ -546,23 +546,35 @@ void PlayListWidget::addSelected() {
case 0: //playlist
return;
break;
case 1: { //audio
- filename=audioView->currentItem()->text(3);
- // d->selectedFiles->next();
+ QListViewItemIterator it( audioView );
+ for ( ; it.current(); ++it ) {
+ if ( it.current()->isSelected() ) {
+ filename=it.current()->text(3);
+ lnk.setName( QFileInfo(filename).baseName() ); //sets name
+ lnk.setFile( filename ); //sets file name
+ d->selectedFiles->addToSelection( lnk);
+ }
+ }
}
break;
case 2: { // video
- filename=videoView->currentItem()->text(3);
- // tabWidget->setCurrentPage(0);
+ QListViewItemIterator it( videoView );
+ for ( ; it.current(); ++it ) {
+ if ( it.current()->isSelected() ) {
+ // myFile = (*it);
- }
- break;
- };
+ filename=it.current()->text(3);
lnk.setName( QFileInfo(filename).baseName() ); //sets name
lnk.setFile( filename ); //sets file name
d->selectedFiles->addToSelection( lnk);
+ }
+ }
+ }
+ break;
+ };
tabWidget->setCurrentPage(0);
writeCurrentM3u();
}
@@ -995,9 +1007,9 @@ void PlayListWidget::writem3u() {
if(fileDlg) delete fileDlg;
DocLnk lnk;
lnk.setFile( filename);
-// lnk.setIcon("opieplayer2/playlist2");
+ lnk.setIcon("opieplayer2/playlist2");
lnk.setName( name); //sets file name
// qDebug(filename);
Config config( "OpiePlayer" );