/// <summary> /// window reposition /// </summary> /// <param name="m"></param> private void WindowReposition(Message m) { RepositionEventArgs repositionEventArgs = new RepositionEventArgs(); if (CanReposition != null) { NativeWindowCommon.WINDOWPOS wp = new NativeWindowCommon.WINDOWPOS(); wp = (NativeWindowCommon.WINDOWPOS)m.GetLParam(typeof(NativeWindowCommon.WINDOWPOS)); repositionEventArgs.HwndInsertAfter = wp.hwndInsertAfter; CanReposition(this, repositionEventArgs); if (!repositionEventArgs.CanReposition) { wp.flags |= NativeWindowCommon.SWP_NOZORDER; Marshal.StructureToPtr(wp, m.LParam, true); } } }
internal void CanRepositionHandler(Object sender, RepositionEventArgs e) { handleEvent(EventType.CAN_REPOSITION, sender, e); }