1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-04-08 10:02:29 +02:00

Update tomahawk volume when phonon volume is updated externally, lessen deafness

This commit is contained in:
Leo Franchi 2011-06-05 15:44:30 -04:00
parent bee2a7165a
commit 24502d8856
2 changed files with 3 additions and 2 deletions

View File

@ -62,6 +62,8 @@ AudioEngine::AudioEngine()
connect( m_mediaObject, SIGNAL( stateChanged( Phonon::State, Phonon::State ) ), SLOT( onStateChanged( Phonon::State, Phonon::State ) ) );
connect( m_mediaObject, SIGNAL( tick( qint64 ) ), SLOT( timerTriggered( qint64 ) ) );
connect( m_mediaObject, SIGNAL( aboutToFinish() ), SLOT( onAboutToFinish() ) );
connect( m_audioOutput, SIGNAL( volumeChanged( qreal ) ), this, SLOT( onVolumeChanged( qreal ) ) );
}
@ -173,7 +175,6 @@ AudioEngine::setVolume( int percentage )
emit volumeChanged( percentage );
}
void
AudioEngine::mute()
{

View File

@ -68,7 +68,7 @@ public slots:
void setVolume( int percentage );
void lowerVolume() { setVolume( volume() - AUDIO_VOLUME_STEP ); }
void raiseVolume() { setVolume( volume() + AUDIO_VOLUME_STEP ); }
void onVolumeChanged( float volume ) { emit volumeChanged( volume * 100 ); }
void onVolumeChanged( qreal volume ) { emit volumeChanged( volume * 100 ); }
void mute();
void playItem( PlaylistInterface* playlist, const Tomahawk::result_ptr& result );