private void SendCommand(XCommand x, ClownfishStatus y) { string sendCommand = string.Format("{0}|{1}", (int)x, (int)y); COPYDATASTRUCT cds = new COPYDATASTRUCT(); cds.dwData = new IntPtr(42); cds.cbData = sendCommand.Length; cds.lpData = sendCommand; UnsafeMethods.SendMessage(new IntPtr(_clownfishWnd), WM_COPYDATA, IntPtr.Zero, ref cds); }
public void ControlClownfish(ClownfishStatus status) { SendCommand(XCommand.ClownfishControl, status); }