When something changes in the global MidiShare environment all the context alarms (see MidiSetApplAlarm and MidiGetApplAlarm) are called with a 32-bits code : 0xRRRRMMMM where RRRR is the reference number of the application involved and MMMM the type of change defined as follows :
#define MIDIOpenAppl 1 // an application was open #define MIDICloseAppl 2 // an application was closed #define MIDIChgName 3 // an application name has changed #define MIDIChgConnect 4 // a connection has changed #define MIDIOpenModem 5 // the modem port was open #define MIDICloseModem 6 // the modem port was closed #define MIDIOpenPrinter 7 // the printer port was open #define MIDIClosePrinter 8 // the printer port was closed #define MIDISyncStart 9 // MidiShare is now locked to SMPTE sync #define MIDISyncStop 10 // SMPTE sync disappeard, MidiShare is now unlocked #define MIDIChangeSync 11 // the synchronisation mode has changed