mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-13 17:43:59 +02:00
* Work-around VLC bug: reset volume when resuming.
This commit is contained in:
@@ -132,7 +132,9 @@ AudioEngine::play()
|
|||||||
|
|
||||||
if ( isPaused() )
|
if ( isPaused() )
|
||||||
{
|
{
|
||||||
|
setVolume( m_volume );
|
||||||
m_mediaObject->play();
|
m_mediaObject->play();
|
||||||
|
setVolume( m_volume );
|
||||||
emit resumed();
|
emit resumed();
|
||||||
|
|
||||||
if ( TomahawkSettings::instance()->privateListeningMode() != TomahawkSettings::FullyPrivate )
|
if ( TomahawkSettings::instance()->privateListeningMode() != TomahawkSettings::FullyPrivate )
|
||||||
@@ -145,7 +147,6 @@ AudioEngine::play()
|
|||||||
trackInfo["albumpos"] = QString::number( m_currentTrack->albumpos() );
|
trackInfo["albumpos"] = QString::number( m_currentTrack->albumpos() );
|
||||||
trackInfo["duration"] = QString::number( m_currentTrack->duration() );
|
trackInfo["duration"] = QString::number( m_currentTrack->duration() );
|
||||||
|
|
||||||
|
|
||||||
Tomahawk::InfoSystem::InfoSystem::instance()->pushInfo(
|
Tomahawk::InfoSystem::InfoSystem::instance()->pushInfo(
|
||||||
s_aeInfoIdentifier, Tomahawk::InfoSystem::InfoNowResumed,
|
s_aeInfoIdentifier, Tomahawk::InfoSystem::InfoNowResumed,
|
||||||
QVariant::fromValue< Tomahawk::InfoSystem::InfoStringHash >( trackInfo ),
|
QVariant::fromValue< Tomahawk::InfoSystem::InfoStringHash >( trackInfo ),
|
||||||
@@ -162,6 +163,7 @@ AudioEngine::pause()
|
|||||||
{
|
{
|
||||||
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
|
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
|
||||||
|
|
||||||
|
m_volume = volume();
|
||||||
m_mediaObject->pause();
|
m_mediaObject->pause();
|
||||||
emit paused();
|
emit paused();
|
||||||
|
|
||||||
|
@@ -160,6 +160,7 @@ private:
|
|||||||
|
|
||||||
mutable QStringList m_supportedMimeTypes;
|
mutable QStringList m_supportedMimeTypes;
|
||||||
AudioState m_state;
|
AudioState m_state;
|
||||||
|
unsigned int m_volume;
|
||||||
|
|
||||||
static AudioEngine* s_instance;
|
static AudioEngine* s_instance;
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user