示例#1
0
        internal void TestDrop(IDockDragSource dragSource, DockOutlineBase dockOutline)
        {
            if (!dragSource.CanDockTo(this))
            {
                return;
            }

            Point ptMouse = Control.MousePosition;

            HitTestResult hitTestResult = GetHitTest(ptMouse);

            if (hitTestResult.HitArea == HitTestArea.Caption)
            {
                dockOutline.Show(this, -1);
            }
            else if (hitTestResult.HitArea == HitTestArea.TabStrip && hitTestResult.Index != -1)
            {
                dockOutline.Show(this, hitTestResult.Index);
            }
        }
示例#2
0
        internal void TestDrop(IDockDragSource dragSource, DockOutlineBase dockOutline)
        {
            if (VisibleNestedPanes.Count == 1)
            {
                DockPane pane = VisibleNestedPanes[0];
                if (!dragSource.CanDockTo(pane))
                {
                    return;
                }

                Point ptMouse = Control.MousePosition;
                uint  lParam  = Win32Helper.MakeLong(ptMouse.X, ptMouse.Y);
                if (!Win32Helper.IsRunningOnMono)
                {
                    if (NativeMethods.SendMessage(Handle, (int)Win32.Msgs.WM_NCHITTEST, 0, lParam) == (uint)Win32.HitTest.HTCAPTION)
                    {
                        dockOutline.Show(VisibleNestedPanes[0], -1);
                    }
                }
            }
        }
        internal void TestDrop(IDockDragSource dragSource, DockOutlineBase dockOutline)
        {
            if (VisibleNestedPanes.Count == 1)
            {
                DockPane pane = VisibleNestedPanes[0];
                if (!dragSource.CanDockTo(pane))
                    return;

                Point ptMouse = Control.MousePosition;
                uint lParam = Win32Helper.MakeLong(ptMouse.X, ptMouse.Y);
                if (!Win32Helper.IsRunningOnMono)
                    if (NativeMethods.SendMessage(Handle, (int)Win32.Msgs.WM_NCHITTEST, 0, lParam) == (uint)Win32.HitTest.HTCAPTION)
                        dockOutline.Show(VisibleNestedPanes[0], -1);
            }
        }
示例#4
0
        internal void TestDrop(IDockDragSource dragSource, DockOutlineBase dockOutline)
        {
            if (!dragSource.CanDockTo(this))
                return;

            Point ptMouse = Control.MousePosition;

            HitTestResult hitTestResult = GetHitTest(ptMouse);
            if (hitTestResult.HitArea == HitTestArea.Caption)
                dockOutline.Show(this, -1);
            else if (hitTestResult.HitArea == HitTestArea.TabStrip && hitTestResult.Index != -1)
                dockOutline.Show(this, hitTestResult.Index);
        }
示例#5
0
 internal void TestDrop(IDockDragSource dragSource, DockOutlineBase dockOutline)
 {
     if(this.VisibleNestedPanes.Count == 1){
         DockPane pane = this.VisibleNestedPanes[0];
         if(!dragSource.CanDockTo(pane)){
             return;
         }
         Point ptMouse = MousePosition;
         uint lParam = Win32Helper.MakeLong(ptMouse.X, ptMouse.Y);
         if(NativeMethods.SendMessage(this.Handle, (int)Msgs.WM_NCHITTEST, 0, lParam) == (uint)HitTest.HTCAPTION){
             dockOutline.Show(this.VisibleNestedPanes[0], -1);
         }
     }
 }