You've already forked lazarus-ccr
LazMapViewer: Add missing GPSItems.Lock/Unlock to DrawTrack method.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8108 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -616,8 +616,11 @@ var
|
|||||||
trkColor: TColor;
|
trkColor: TColor;
|
||||||
trkWidth: Integer;
|
trkWidth: Integer;
|
||||||
begin
|
begin
|
||||||
if trk.Visible and (trk.Points.Count > 0) then
|
if not trk.Visible or (trk.Points.Count = 0) then
|
||||||
begin
|
exit;
|
||||||
|
|
||||||
|
GPSItems.Lock;
|
||||||
|
try
|
||||||
// Determine track color
|
// Determine track color
|
||||||
if trk.LineColor = clDefault then
|
if trk.LineColor = clDefault then
|
||||||
begin
|
begin
|
||||||
@ -657,6 +660,8 @@ begin
|
|||||||
LastInside := IsInside;
|
LastInside := IsInside;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
finally
|
||||||
|
GPSItems.Unlock;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user