lcl: disable docking at the design time (#0012772)

git-svn-id: trunk@17776 -
This commit is contained in:
paul 2008-12-10 01:56:37 +00:00
parent 15de8d3289
commit 3659841c55
3 changed files with 3 additions and 1 deletions

View File

@ -169,6 +169,7 @@ begin
{$ifdef windows}
if (PMSG(xevent)^.message = WM_NCLBUTTONDOWN) and
(PMSG(xevent)^.wParam = HTCAPTION) and
not (csDesigning in AForm.ComponentState) and
(TWinControlAccess(TWinControl(AForm)).DragKind = dkDock) and
(TWinControlAccess(TWinControl(AForm)).DragMode = dmAutomatic) then
begin

View File

@ -2217,6 +2217,7 @@ var
begin
//Drag&Dock support TCustomForm => Start BeginDrag()
if (LCLObject is TCustomForm) and
not (csDesigning in LCLObject.ComponentState) and
(TWinControlAccess(LCLObject).DragKind = dkDock) and
(TWinControlAccess(LCLObject).DragMode = dmAutomatic) and
(QMouseEvent_button(QMouseEventH(Event)) = QtLeftButton) then

View File

@ -1911,7 +1911,7 @@ begin
Assert(False, 'Trace:WindowProc - Got WM_NCLBUTTONDOWN');
//Drag&Dock support TCustomForm => Start BeginDrag()
if lWinControl <> nil then
if (lWinControl <> nil) and not (csDesigning in lWinControl.ComponentState) then
begin
if WParam = HTCAPTION then
begin