Курсовая работа: Поиск кратчайшего пути в многоугольнике
end;
end;
//изменениеначала
if ((btnstart.Tag=1)and((sender as tshape).Brush.Color=clyellow))
then index2:=false;
if (btnstart.Tag=1)and((sender as tshape).Brush.Color=clgreen)
or((btnstart.Tag=1)and((sender as tshape).Brush.Color=clyellow))
then begin(sender as tshape).Brush.Color:=clblue;index1:=true;
btnstart.Tag:=0 end;
//изменениеконца
if ((btnfinish.Tag=1)and((sender as tshape).Brush.Color=clblue))
then index1:=false;
if (btnfinish.Tag=1)and((sender as tshape).Brush.Color=clgreen)
or((btnfinish.Tag=1)and((sender as tshape).Brush.Color=clblue))
then begin btnfinish.Tag:=0;index2:=true;
(sender as tshape).Brush.Color:=clyellow end;
if (index1=true) and (index2=true) then btnGraph.Enabled:=true;
end;
procedure TForm1.FormCreate(Sender: TObject);
var i,j,n:integer;
begin
k:=0;
panel1.Tag:=0;
btnstart.Enabled:=false;
btnfinish.Enabled:=false;
btnGraph.Enabled:=false;
n:=nMaxShape;
//self.WindowState:=wsMaximized;
for i:=0 to n-1 do