public LaunchpadController() { Instance = this; InitScreen(); FindPad(); if (Output == null || Input == null) { MessageBox.Show("Unable to find MIDI input or MIDI output!", "Error", MessageBoxButtons.OK); return; } Log.Debug("Located input and output of Launchpad MIDI"); if (OpenConnection()) { MidiMessageHandler.Instance().Init(Input, Output); LaunchPageHandler.Instance().CreatePages(); Log.Info("Everything is set up and working!"); } Application.Run(Screen); }
public static void ResetPad() { MidiMessageHandler.Instance().ClearPad(); }
public static void TellPad(int key, KeyColor color) { MidiMessageHandler.Instance().SendMessage(key, (int)color); }