コード例 #1
0
        public static LaunchEventHandler Instance()
        {
            if (instance == null)
            {
                instance = new LaunchEventHandler();
            }

            return(instance);
        }
コード例 #2
0
        public void Init(InputDevice input, OutputDevice output)
        {
            this.input              = input;
            this.output             = output;
            this.LaunchEventHandler = LaunchEventHandler.Instance();

            LaunchEventHandler.LaunchEvents += new LaunchEventHandler.KeyPressedHandler(this.KeyPressedEvent);
            input.ControlChange             += new InputDevice.ControlChangeHandler(this.ControlChange);
            input.NoteOn  += new InputDevice.NoteOnHandler(this.NoteOnHandler);
            input.NoteOff += new InputDevice.NoteOffHandler(this.NoteOffHandler);
        }