/// <summary> /// Callback method that is called when the IClickTypeSelector has sent a ClickType (will send the actual click) /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void SendClick( object sender, ClickTypeEventArgs e ) { foreach( ClickInstruction instr in e.ClickVM ) { switch( instr ) { case ClickInstruction.None: break; case ClickInstruction.RightButtonDown: CK.Plugins.SendInputDriver.MouseProcessor.CurrentPositionRightDown(); break; case ClickInstruction.RightButtonUp: CK.Plugins.SendInputDriver.MouseProcessor.CurrentPositionRightUp(); break; case ClickInstruction.LeftButtonDown: CK.Plugins.SendInputDriver.MouseProcessor.CurrentPositionLeftDown(); break; case ClickInstruction.LeftButtonUp: CK.Plugins.SendInputDriver.MouseProcessor.CurrentPositionLeftUp(); break; case ClickInstruction.WheelDown: CK.Plugins.SendInputDriver.MouseProcessor.CurrentPositionMiddleDown(); break; case ClickInstruction.WheelUp: CK.Plugins.SendInputDriver.MouseProcessor.CurrentPositionMiddleUp(); break; default: break; } } }
/// <summary> /// Callback method that is called when the IClickSelector has sent a Click (will send the actual click) /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void OnClickChosen( object sender, ClickTypeEventArgs e ) { foreach( ClickInstruction instr in e.ClickVM ) { switch( instr ) { case ClickInstruction.None: break; case ClickInstruction.RightButtonDown: MouseProcessor.RightButtonDown(); break; case ClickInstruction.RightButtonUp: MouseProcessor.RightButtonUp(); break; case ClickInstruction.LeftButtonDown: MouseProcessor.LeftButtonDown(); break; case ClickInstruction.LeftButtonUp: MouseProcessor.LeftButtonUp(); break; case ClickInstruction.WheelDown: MouseProcessor.MiddleButtonDown(); break; case ClickInstruction.WheelUp: MouseProcessor.MiddleButtonUp(); break; default: break; } } }