LCL: TDragDockObject.HideDockImage check if something to hide

git-svn-id: trunk@26271 -
This commit is contained in:
mattias 2010-06-23 15:15:40 +00:00
parent 7f8a4f287d
commit 241c05aaae
2 changed files with 4 additions and 3 deletions

View File

@ -229,7 +229,7 @@ begin
try try
// restore the layout // restore the layout
// this will close unneeded forms and call OnCreateControl for all needed // this will close unneeded forms and call OnCreateControl for all needed
DockMaster.LoadLayoutFromConfig(XMLConfig); DockMaster.LoadLayoutFromConfig(XMLConfig,true);
finally finally
XMLConfig.Free; XMLConfig.Free;
end; end;

View File

@ -147,14 +147,15 @@ end;
procedure TDragDockObject.HideDockImage; procedure TDragDockObject.HideDockImage;
begin begin
WidgetSet.DrawDefaultDockImage(EraseDockRect, DockRect, disHide); if FEraseDockRect.Left<MaxInt then
WidgetSet.DrawDefaultDockImage(EraseDockRect, DockRect, disHide);
FEraseDockRect := Rect(MaxInt, 0, MaxInt, 0); FEraseDockRect := Rect(MaxInt, 0, MaxInt, 0);
end; end;
procedure TDragDockObject.MoveDockImage; procedure TDragDockObject.MoveDockImage;
begin begin
//Draw the form outlines when the position has changed //Draw the form outlines when the position has changed
if not CompareMem(@DockRect, @EraseDockRect, SizeOf(TRect)) then if not CompareRect(@DockRect, @EraseDockRect) then
begin begin
WidgetSet.DrawDefaultDockImage(EraseDockRect, DockRect, disMove); WidgetSet.DrawDefaultDockImage(EraseDockRect, DockRect, disMove);
EraseDockRect := DockRect; EraseDockRect := DockRect;