-rw-r--r-- | core/multimedia/opieplayer/playlistwidget.cpp | 27 |
1 files changed, 9 insertions, 18 deletions
diff --git a/core/multimedia/opieplayer/playlistwidget.cpp b/core/multimedia/opieplayer/playlistwidget.cpp index 26103c3..65dc5fb 100644 --- a/core/multimedia/opieplayer/playlistwidget.cpp +++ b/core/multimedia/opieplayer/playlistwidget.cpp | |||
@@ -497,6 +497,8 @@ void PlayListWidget::setDocument(const QString& fileref) { | |||
497 | 497 | ||
498 | 498 | ||
499 | void PlayListWidget::setActiveWindow() { | 499 | void PlayListWidget::setActiveWindow() { |
500 | qDebug("SETTING active window"); | ||
501 | |||
500 | // When we get raised we need to ensure that it switches views | 502 | // When we get raised we need to ensure that it switches views |
501 | char origView = mediaPlayerState->view(); | 503 | char origView = mediaPlayerState->view(); |
502 | mediaPlayerState->setView( 'l' ); // invalidate | 504 | mediaPlayerState->setView( 'l' ); // invalidate |
@@ -956,15 +958,11 @@ void PlayListWidget::listDelete() { | |||
956 | break; | 958 | break; |
957 | case 1: | 959 | case 1: |
958 | { | 960 | { |
959 | file = audioView->selectedItem()->text(0); | 961 | file = audioView->currentItem()->text(0); |
960 | // Global::findDocuments(&files, "audio/*"); | 962 | QListIterator<DocLnk> Pdit( files.children() ); |
961 | // AppLnkSet appFiles; | 963 | for ( ; Pdit.current(); ++Pdit ) { |
962 | QListIterator<DocLnk> dit( files.children() ); | 964 | if( Pdit.current()->name() == file) { |
963 | for ( ; dit.current(); ++dit ) { | 965 | LnkProperties prop( Pdit.current() ); |
964 | if( dit.current()->name() == file) { | ||
965 | // qDebug(file); | ||
966 | LnkProperties prop( dit.current() ); | ||
967 | // connect(&prop, SIGNAL(select(const AppLnk *)), this, SLOT(externalSelected(const AppLnk *))); | ||
968 | prop.showMaximized(); | 966 | prop.showMaximized(); |
969 | prop.exec(); | 967 | prop.exec(); |
970 | } | 968 | } |
@@ -1079,10 +1077,6 @@ void PlayListWidget::openFile() { | |||
1079 | // http://205.188.234.129:8030 | 1077 | // http://205.188.234.129:8030 |
1080 | // http://66.28.68.70:8000 | 1078 | // http://66.28.68.70:8000 |
1081 | // filename.replace(QRegExp("%20")," "); | 1079 | // filename.replace(QRegExp("%20")," "); |
1082 | if(filename.find(" ",0,TRUE) != -1 || filename.find("%20",0,TRUE) != -1) { | ||
1083 | QMessageBox::message("Note","Spaces in urls are not allowed."); | ||
1084 | return; | ||
1085 | } else { | ||
1086 | qDebug("Selected filename is "+filename); | 1080 | qDebug("Selected filename is "+filename); |
1087 | if(filename.right(3) == "m3u") | 1081 | if(filename.right(3) == "m3u") |
1088 | readm3u( filename); | 1082 | readm3u( filename); |
@@ -1106,7 +1100,6 @@ void PlayListWidget::openFile() { | |||
1106 | // if(fileDlg2) | 1100 | // if(fileDlg2) |
1107 | // delete fileDlg2; | 1101 | // delete fileDlg2; |
1108 | } | 1102 | } |
1109 | } | ||
1110 | } | 1103 | } |
1111 | if(fileDlg) | 1104 | if(fileDlg) |
1112 | delete fileDlg; | 1105 | delete fileDlg; |
@@ -1230,10 +1223,8 @@ void PlayListWidget::readm3u(const QString &filename) { | |||
1230 | while ( !t.atEnd()) { | 1223 | while ( !t.atEnd()) { |
1231 | // Lview->insertLine(t.readLine(),-1); | 1224 | // Lview->insertLine(t.readLine(),-1); |
1232 | s=t.readLine(); | 1225 | s=t.readLine(); |
1233 | if(s.find(" ",0,TRUE) != -1 || s.find("%20",0,TRUE) != -1) { | 1226 | |
1234 | QMessageBox::message("Note","Spaces in urls are not allowed."); | 1227 | if(s.find("#",0,TRUE) == -1) { |
1235 | } | ||
1236 | else if(s.find("#",0,TRUE) == -1) { | ||
1237 | if(s.find(" ",0,TRUE) == -1) { // not sure if this is neede since cf uses vfat | 1228 | if(s.find(" ",0,TRUE) == -1) { // not sure if this is neede since cf uses vfat |
1238 | if(s.left(2) == "E:" || s.left(2) == "P:") { | 1229 | if(s.left(2) == "E:" || s.left(2) == "P:") { |
1239 | s=s.right(s.length()-2); | 1230 | s=s.right(s.length()-2); |