diff --git a/src/Train/TrainSidebar.cpp b/src/Train/TrainSidebar.cpp index 64a43c411..d2c67a9f1 100644 --- a/src/Train/TrainSidebar.cpp +++ b/src/Train/TrainSidebar.cpp @@ -40,7 +40,11 @@ #include #include +#if QT_VERSION >= 0x060000 #include +#else +#include +#endif // Three current realtime device types supported are: #include "RealtimeController.h" @@ -2078,9 +2082,13 @@ void TrainSidebar::guiUpdate() // refreshes the telemetry if (fPlayAudio) { lapAudioThisLap = false; +#if QT_VERSION >= 0x060000 QSoundEffect effect; effect.setSource(QUrl::fromLocalFile(":audio/lap.wav")); effect.play(); +#else + QSound::play(":audio/lap.wav"); +#endif } }