Exemple #1
0
void CMfxEvent::setToDefaults()
{
	SetTime( 0 );
	SetPort( 0 );
	SetChannel( 0 );

	switch (GetType())
	{
		case Note:
			SetKey( 60 );
			SetVel( 64 );
			SetDur( 120 );
			break;

		case KeyAft:
			SetKey( 60 );
			SetPressure( 0 );
			break;

		case Control:
			SetCtrlNum( CTL_MODULATION );
			SetCtrlVal( 0 );
			break;

		case Patch:
			SetBankSelectMethod( Normal );
			SetBank( BANK_NONE );
			SetPatch( 0 );
			break;

		case ChanAft:
			SetPressure( 0 );
			break;

		case Wheel:
			SetWheel( 0 );
			break;

		case RPN:
		case NRPN:
			SetCtrlNum( 0 );
			SetCtrlVal( 0 );
			break;

		case Sysx:
		case Text:
		case Lyric:
			m_hBuffer = NULL;
			break;

		case MuteMask:
			m_mfxChannel = 0;
			m_maskSet = 0;
			m_maskClear = 0;
			break;

		case VelOfs:
		case KeyOfs:
			m_mfxChannel = 0;
			m_nOfs = 0;
			break;

		case VelTrim:
		case KeyTrim:
			m_mfxChannel = 0;
			m_nTrim = 0;
			break;

		case ShortMsg:
			m_dwShortMsg = 0;
			break;
			
		default:
			ASSERT(FALSE);
			break;
	}
}
Exemple #2
0
void SetDur7(GtkAction *action, gpointer param){
  SetDur(7);
}
Exemple #3
0
void SetDur8(GtkAction *action, gpointer param){
  SetDur(8);
}
Exemple #4
0
void SetDur5(GtkAction *action, gpointer param){
  SetDur(5);
}
Exemple #5
0
void SetDur6(GtkAction *action, gpointer param){
  SetDur(6);
}
Exemple #6
0
void SetDur4(GtkAction *action, gpointer param){
  SetDur(4);
}
Exemple #7
0
void SetDur3(GtkAction *action, gpointer param){
  SetDur(3);
}
Exemple #8
0
void SetDur2(GtkAction *action, gpointer param){
  SetDur(2);
}
Exemple #9
0
void SetDur1(GtkAction *action, gpointer param){
  SetDur(1);
}
Exemple #10
0
void SetDur0(GtkAction *action, gpointer param){
  SetDur(0);
}