Rename __targetNames to targetNames, and make it a static member variable
This commit is contained in:
@@ -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
|
||||
|
||||
@@ -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() );
|
||||
|
||||
@@ -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() ) );
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user