1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-11 16:44:05 +02:00

Fix compilation with libvlc < 2.2.2

This commit is contained in:
Dominik Schmidt
2016-02-22 15:53:20 +01:00
parent 8b3a916aa6
commit 5075c9ddbf

View File

@@ -123,9 +123,11 @@ AudioOutput::AudioOutput( QObject* parent )
libvlc_MediaPlayerTitleChanged, libvlc_MediaPlayerTitleChanged,
libvlc_MediaPlayerSnapshotTaken, libvlc_MediaPlayerSnapshotTaken,
//libvlc_MediaPlayerLengthChanged, //libvlc_MediaPlayerLengthChanged,
#if (LIBVLC_VERSION_INT >= LIBVLC_VERSION(2, 2, 2, 0))
libvlc_MediaPlayerAudioVolume, libvlc_MediaPlayerAudioVolume,
libvlc_MediaPlayerMuted, libvlc_MediaPlayerMuted,
libvlc_MediaPlayerUnmuted, libvlc_MediaPlayerUnmuted,
#endif
libvlc_MediaPlayerVout libvlc_MediaPlayerVout
}; };
const int eventCount = sizeof(events) / sizeof( *events ); const int eventCount = sizeof(events) / sizeof( *events );
@@ -581,6 +583,7 @@ AudioOutput::onVlcEvent( const libvlc_event_t* event )
// Don't call stop() here - it will deadlock libvlc // Don't call stop() here - it will deadlock libvlc
setState( Error ); setState( Error );
break; break;
#if (LIBVLC_VERSION_INT >= LIBVLC_VERSION(2, 2, 2, 0))
case libvlc_MediaPlayerAudioVolume: case libvlc_MediaPlayerAudioVolume:
m_volume = event->u.media_player_audio_volume.volume; m_volume = event->u.media_player_audio_volume.volume;
emit volumeChanged( volume() ); emit volumeChanged( volume() );
@@ -593,6 +596,7 @@ AudioOutput::onVlcEvent( const libvlc_event_t* event )
m_muted = false; m_muted = false;
emit mutedChanged( false ); emit mutedChanged( false );
break; break;
#endif
case libvlc_MediaPlayerNothingSpecial: case libvlc_MediaPlayerNothingSpecial:
case libvlc_MediaPlayerOpening: case libvlc_MediaPlayerOpening:
case libvlc_MediaPlayerBuffering: case libvlc_MediaPlayerBuffering: