From 5cc3b1132677766b8f5c63928680c381c8bb46db Mon Sep 17 00:00:00 2001 From: admsasha Date: Fri, 22 Feb 2019 09:21:09 +0900 Subject: [PATCH] fix translate InstrumentNames --- src/TrackList.cpp | 2 +- src/TrackList.h | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/TrackList.cpp b/src/TrackList.cpp index 0147930..803d161 100644 --- a/src/TrackList.cpp +++ b/src/TrackList.cpp @@ -484,7 +484,7 @@ QString CTrackList::getProgramName(int program) }; if (program >= 0 && program < static_cast(arraySize(gmInstrumentNames))) - return QObject::tr(gmInstrumentNames[program]); + return tr(gmInstrumentNames[program]); else return QString(); } diff --git a/src/TrackList.h b/src/TrackList.h index 20bb4c6..bfa8e1f 100644 --- a/src/TrackList.h +++ b/src/TrackList.h @@ -32,6 +32,7 @@ #include #include #include +#include #include "MidiEvent.h" #include "Chord.h" @@ -49,8 +50,9 @@ public: }; -class CTrackList +class CTrackList : public QObject { +Q_OBJECT public: CTrackList() {