Fix bug tracking latching state
Fix bug tracking latching state

Since the latching state was determined from the last value sent, we
couldn't figure out the state if both the "on" and "off" values were
either >= or < 128.  Instead, track it explicitly in a new LatchState
array.

Also fix an embarassing typo with note events.

brianj29/MidiController,brianj29/MidiController