diff --git a/include/InstrumentSoundShaping.h b/include/InstrumentSoundShaping.h index 90405a414..31e8cc75e 100644 --- a/include/InstrumentSoundShaping.h +++ b/include/InstrumentSoundShaping.h @@ -75,6 +75,8 @@ private: FloatModel m_filterCutModel; FloatModel m_filterResModel; + static const QString targetNames[InstrumentSoundShaping::NumTargets][3]; + friend class InstrumentSoundShapingView; friend class FlpImport; @@ -82,7 +84,4 @@ private: } ; -extern const QString __targetNames[InstrumentSoundShaping::NumTargets][3]; - - #endif diff --git a/src/core/InstrumentSoundShaping.cpp b/src/core/InstrumentSoundShaping.cpp index b95bacc15..1dc6c0337 100644 --- a/src/core/InstrumentSoundShaping.cpp +++ b/src/core/InstrumentSoundShaping.cpp @@ -42,7 +42,7 @@ const float RES_PRECISION = 1000.0f; // names for env- and lfo-targets - first is name being displayed to user // and second one is used internally, e.g. for saving/restoring settings -const QString __targetNames[InstrumentSoundShaping::NumTargets][3] = +const QString InstrumentSoundShaping::targetNames[InstrumentSoundShaping::NumTargets][3] = { { InstrumentSoundShaping::tr( "VOLUME" ), "vol", InstrumentSoundShaping::tr( "Volume" ) }, @@ -76,7 +76,7 @@ InstrumentSoundShaping::InstrumentSoundShaping( value_for_zero_amount, this ); m_envLfoParameters[i]->setDisplayName( - tr( __targetNames[i][2].toUtf8().constData() ) ); + tr( targetNames[i][2].toUtf8().constData() ) ); } m_filterModel.addItem( tr( "LowPass" ), new PixmapLoader( "filter_lp" ) ); @@ -331,7 +331,7 @@ void InstrumentSoundShaping::saveSettings( QDomDocument & _doc, QDomElement & _t { m_envLfoParameters[i]->saveState( _doc, _this ).setTagName( m_envLfoParameters[i]->nodeName() + - QString( __targetNames[i][1] ).toLower() ); + QString( targetNames[i][1] ).toLower() ); } } @@ -354,7 +354,7 @@ void InstrumentSoundShaping::loadSettings( const QDomElement & _this ) { if( node.nodeName() == m_envLfoParameters[i]->nodeName() + - QString( __targetNames[i][1] ). + QString( targetNames[i][1] ). toLower() ) { m_envLfoParameters[i]->restoreState( node.toElement() ); diff --git a/src/gui/widgets/InstrumentSoundShapingView.cpp b/src/gui/widgets/InstrumentSoundShapingView.cpp index 39637e7e7..8c2eb76ab 100644 --- a/src/gui/widgets/InstrumentSoundShapingView.cpp +++ b/src/gui/widgets/InstrumentSoundShapingView.cpp @@ -76,7 +76,7 @@ InstrumentSoundShapingView::InstrumentSoundShapingView( QWidget * _parent ) : { m_envLfoViews[i] = new EnvelopeAndLfoView( m_targetsTabWidget ); m_targetsTabWidget->addTab( m_envLfoViews[i], - tr( __targetNames[i][0].toUtf8().constData() ) ); + tr( InstrumentSoundShaping::targetNames[i][0].toUtf8().constData() ) ); }