author | llornkcor <llornkcor> | 2002-06-13 04:46:12 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2002-06-13 04:46:12 (UTC) |
commit | 7ab4c2b4684287ac5f629445abcedb34ebfce9f3 (patch) (side-by-side diff) | |
tree | 28a17efdd2ac4a3b2193b27e14dbd96740fffc66 /core/multimedia/opieplayer | |
parent | 7239ae505999b64c74479c460daba256baf82798 (diff) | |
download | opie-7ab4c2b4684287ac5f629445abcedb34ebfce9f3.zip opie-7ab4c2b4684287ac5f629445abcedb34ebfce9f3.tar.gz opie-7ab4c2b4684287ac5f629445abcedb34ebfce9f3.tar.bz2 |
bugfix: menu select play works again
-rw-r--r-- | core/multimedia/opieplayer/audiodevice.cpp | 4 | ||||
-rw-r--r-- | core/multimedia/opieplayer/playlistwidget.cpp | 25 | ||||
-rw-r--r-- | core/multimedia/opieplayer/playlistwidget.h | 2 |
3 files changed, 14 insertions, 17 deletions
diff --git a/core/multimedia/opieplayer/audiodevice.cpp b/core/multimedia/opieplayer/audiodevice.cpp index e0989d0..3262e38 100644 --- a/core/multimedia/opieplayer/audiodevice.cpp +++ b/core/multimedia/opieplayer/audiodevice.cpp @@ -20,4 +20,5 @@ // L.J.Potter added better error code Fri 02-15-2002 14:37:47 + #include <stdlib.h> #include <stdio.h> @@ -189,4 +190,5 @@ void AudioDevice::setVolume( unsigned int leftVolume, unsigned int rightVolume, AudioDevice::AudioDevice( unsigned int f, unsigned int chs, unsigned int bps ) { qDebug("creating new audio device"); + QCopEnvelope( "QPE/System", "volumeChange(bool)" ) << TRUE; d = new AudioDevicePrivate; d->frequency = f; @@ -204,5 +206,4 @@ AudioDevice::AudioDevice( unsigned int f, unsigned int chs, unsigned int bps ) { int capabilities = 0; - QCopEnvelope( "QPE/System", "volumeChange(bool)" ) << TRUE; #ifdef KEEP_DEVICE_OPEN @@ -265,5 +266,4 @@ AudioDevice::~AudioDevice() { delete d; #endif - QCopEnvelope( "QPE/System", "volumeChange(bool)" ) << FALSE; } diff --git a/core/multimedia/opieplayer/playlistwidget.cpp b/core/multimedia/opieplayer/playlistwidget.cpp index 930560e..d7447b7 100644 --- a/core/multimedia/opieplayer/playlistwidget.cpp +++ b/core/multimedia/opieplayer/playlistwidget.cpp @@ -841,6 +841,5 @@ void PlayListWidget::btnPlay(bool b) { case 1: { -// if(audioView->selectedItem()) { - addToSelection( audioView->selectedItem() ); + addToSelection( audioView->currentItem() ); mediaPlayerState->setPlaying(b); d->selectedFiles->removeSelected( ); @@ -849,11 +848,9 @@ void PlayListWidget::btnPlay(bool b) { insanityBool=FALSE; // audioView->clearSelection(); -// } } break; case 2: { -// if(videoView->selectedItem() ) { - addToSelection( videoView->selectedItem() ); + addToSelection( videoView->currentItem() ); mediaPlayerState->setPlaying(b); qApp->processEvents(); @@ -863,5 +860,4 @@ void PlayListWidget::btnPlay(bool b) { insanityBool=FALSE; // videoView->clearSelection(); -// } } break; @@ -889,14 +885,15 @@ void PlayListWidget::viewPressed( int mouse, QListViewItem *item, const QPoint& break; case 2:{ - QPopupMenu m; - m.insertItem( tr( "Play" ), this, SLOT( playSelected() )); - m.insertItem( tr( "Add to Playlist" ), this, SLOT( addSelected() )); - m.insertSeparator(); - if( QFile(QPEApplication::qpeDir()+"lib/libopie.so").exists() ) - m.insertItem( tr( "Properties" ), this, SLOT( listDelete() )); + + QPopupMenu m; + m.insertItem( tr( "Play" ), this, SLOT( playSelected() )); + m.insertItem( tr( "Add to Playlist" ), this, SLOT( addSelected() )); + m.insertSeparator(); + if( QFile(QPEApplication::qpeDir()+"lib/libopie.so").exists() ) + m.insertItem( tr( "Properties" ), this, SLOT( listDelete() )); - m.exec( QCursor::pos() ); + m.exec( QCursor::pos() ); } - break; + break; }; } diff --git a/core/multimedia/opieplayer/playlistwidget.h b/core/multimedia/opieplayer/playlistwidget.h index 6569f35..5837ed3 100644 --- a/core/multimedia/opieplayer/playlistwidget.h +++ b/core/multimedia/opieplayer/playlistwidget.h @@ -58,5 +58,5 @@ public: FileSelector* playLists; QPushButton *tbDeletePlaylist; - int fd; + int fd, selected; public slots: bool first(); |