mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-05-29 21:24:45 +02:00
dont use direct call of TControl.DoEndDock from DockPerformer (hint from Marius)
git-svn-id: trunk@13971 -
This commit is contained in:
parent
49c34c5cb4
commit
543e960d76
@ -400,6 +400,7 @@ type
|
||||
protected
|
||||
procedure AdjustDockRect(ARect: TRect); virtual;
|
||||
function GetDragCursor(Accepted: Boolean; X, Y: Integer): TCursor; override;
|
||||
procedure EndDrag(Target: TObject; X, Y: Integer); override;
|
||||
public
|
||||
property DockRect: TRect read FDockRect write FDockRect;
|
||||
property DropAlign: TAlign read FDropAlign write FDropAlign;
|
||||
|
@ -536,7 +536,7 @@ begin
|
||||
|
||||
if not Accepted then
|
||||
ADockObjectCopy.Control.DragCanceled;
|
||||
ADockObjectCopy.Control.DoEndDock(ADockObjectCopy.DragTarget,TargetPos.X,TargetPos.Y);
|
||||
ADockObjectCopy.EndDrag(ADockObjectCopy.DragTarget,TargetPos.X,TargetPos.Y);
|
||||
finally
|
||||
if FDragObjectAutoFree then
|
||||
ADockObjectCopy.Free
|
||||
|
@ -99,6 +99,12 @@ begin
|
||||
Result := crDefault;
|
||||
end;
|
||||
|
||||
procedure TDragDockObject.EndDrag(Target: TObject; X, Y: Integer);
|
||||
begin
|
||||
if FControl <> nil then
|
||||
FControl.DoEndDock(Target, X, Y);
|
||||
end;
|
||||
|
||||
|
||||
|
||||
// included by controls.pp
|
||||
|
@ -363,8 +363,6 @@ end;
|
||||
|
||||
class procedure TWin32WSStatusBar.GetPreferredSize(const AWinControl: TWinControl;
|
||||
var PreferredWidth, PreferredHeight: integer; WithThemeSpace: Boolean);
|
||||
var
|
||||
R: TRect;
|
||||
begin
|
||||
if (PreferredStatusBarHeight=0) then
|
||||
InitializePreferredStatusBarHeight;
|
||||
|
Loading…
Reference in New Issue
Block a user