author | llornkcor <llornkcor> | 2002-12-10 11:58:11 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2002-12-10 11:58:11 (UTC) |
commit | 92da6d6ed82230c25d71379eaffbcd222464726b (patch) (unidiff) | |
tree | 57a524c60e9a32b0195aa2fa08e484c533e4ddf7 | |
parent | f468c3bc69655aefa0ec5783405355dd3dde4afc (diff) | |
download | opie-92da6d6ed82230c25d71379eaffbcd222464726b.zip opie-92da6d6ed82230c25d71379eaffbcd222464726b.tar.gz opie-92da6d6ed82230c25d71379eaffbcd222464726b.tar.bz2 |
moving to playlistview after adding to it is annoying some people and me sometimes. try this for now
-rw-r--r-- | noncore/multimedia/opieplayer2/playlistwidget.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/noncore/multimedia/opieplayer2/playlistwidget.cpp b/noncore/multimedia/opieplayer2/playlistwidget.cpp index 27a3286..cba7b6d 100644 --- a/noncore/multimedia/opieplayer2/playlistwidget.cpp +++ b/noncore/multimedia/opieplayer2/playlistwidget.cpp | |||
@@ -200,16 +200,20 @@ void PlayListWidget::addToSelection( const DocLnk& lnk ) { | |||
200 | // writeCurrentM3u(); | 200 | // writeCurrentM3u(); |
201 | } | 201 | } |
202 | 202 | ||
203 | 203 | ||
204 | void PlayListWidget::clearList() { | 204 | void PlayListWidget::clearList() { |
205 | while ( first() ) { | 205 | while ( first() ) { |
206 | d->selectedFiles->removeSelected(); | 206 | d->selectedFiles->removeSelected(); |
207 | } | 207 | } |
208 | Config cfg( "OpiePlayer" ); | ||
209 | cfg.setGroup("PlayList"); | ||
210 | cfg.writeEntry("CurrentPlaylist","default"); | ||
211 | setCaption("OpiePlayer"); | ||
208 | } | 212 | } |
209 | 213 | ||
210 | void PlayListWidget::viewPressed( int mouse, QListViewItem *, const QPoint& , int) { | 214 | void PlayListWidget::viewPressed( int mouse, QListViewItem *, const QPoint& , int) { |
211 | switch (mouse) { | 215 | switch (mouse) { |
212 | case LeftButton: | 216 | case LeftButton: |
213 | break; | 217 | break; |
214 | case RightButton: | 218 | case RightButton: |
215 | { | 219 | { |
@@ -487,17 +491,17 @@ void PlayListWidget::addSelected() { | |||
487 | lnk.setName( QFileInfo( filename ).baseName() ); //sets name | 491 | lnk.setName( QFileInfo( filename ).baseName() ); //sets name |
488 | lnk.setFile( filename ); //sets file name | 492 | lnk.setFile( filename ); //sets file name |
489 | 493 | ||
490 | d->selectedFiles->addToSelection( lnk ); | 494 | d->selectedFiles->addToSelection( lnk ); |
491 | } | 495 | } |
492 | 496 | ||
493 | currentFileListView->clearSelection(); | 497 | currentFileListView->clearSelection(); |
494 | 498 | ||
495 | tabWidget->setCurrentPage( 0 ); | 499 | // tabWidget->setCurrentPage( 0 ); |
496 | writeCurrentM3u(); | 500 | writeCurrentM3u(); |
497 | } | 501 | } |
498 | 502 | ||
499 | 503 | ||
500 | void PlayListWidget::removeSelected() { | 504 | void PlayListWidget::removeSelected() { |
501 | d->selectedFiles->removeSelected( ); | 505 | d->selectedFiles->removeSelected( ); |
502 | writeCurrentM3u(); | 506 | writeCurrentM3u(); |
503 | } | 507 | } |
@@ -522,17 +526,17 @@ void PlayListWidget::addToSelection( QListViewItem *it) { | |||
522 | QString filename; | 526 | QString filename; |
523 | 527 | ||
524 | filename=it->text(3); | 528 | filename=it->text(3); |
525 | lnk.setName( QFileInfo(filename).baseName() ); //sets name | 529 | lnk.setName( QFileInfo(filename).baseName() ); //sets name |
526 | lnk.setFile( filename ); //sets file name | 530 | lnk.setFile( filename ); //sets file name |
527 | d->selectedFiles->addToSelection( lnk); | 531 | d->selectedFiles->addToSelection( lnk); |
528 | 532 | ||
529 | writeCurrentM3u(); | 533 | writeCurrentM3u(); |
530 | tabWidget->setCurrentPage(0); | 534 | // tabWidget->setCurrentPage(0); |
531 | 535 | ||
532 | } | 536 | } |
533 | } | 537 | } |
534 | 538 | ||
535 | 539 | ||
536 | void PlayListWidget::tabChanged(QWidget *) { | 540 | void PlayListWidget::tabChanged(QWidget *) { |
537 | 541 | ||
538 | d->tbPlay->setEnabled( true ); | 542 | d->tbPlay->setEnabled( true ); |