parent
54ef7e59f1
commit
ab4811d834
|
|
@ -435,7 +435,12 @@ type TTslDebuga=class(TCustomControl)
|
|||
begin
|
||||
v.onClick := thisfunction(Dbgtooldo);
|
||||
if v.Caption="添加/删除断点F5" then continue;
|
||||
if v.Caption="继续" then continue;
|
||||
if v.Caption="继续" then
|
||||
begin
|
||||
v.onClick := thisfunction(dbgtooldorun);
|
||||
v.Caption := "运行";
|
||||
continue;
|
||||
end
|
||||
v.Visible := false;
|
||||
end
|
||||
end
|
||||
|
|
@ -560,12 +565,15 @@ type TTslDebuga=class(TCustomControl)
|
|||
end
|
||||
function debugrunredo();
|
||||
begin
|
||||
return dbgtooldorun(nil,nil);
|
||||
if FBtns["终止"].Visible then
|
||||
begin
|
||||
Dbgtooldo(new ttempclass("继续"),nil);
|
||||
//Dbgtooldo(new ttempclass("继续"),nil);
|
||||
dbgtooldorun(nil,nil);
|
||||
end else
|
||||
begin
|
||||
Dbgtooldo(new ttempclass("暂停"),nil);
|
||||
//echo "\r\n 执行run";
|
||||
//Dbgtooldo(new ttempclass("暂停"),nil);
|
||||
end
|
||||
end
|
||||
function Debuglocal(item); //调试脚本
|
||||
|
|
@ -748,6 +756,26 @@ type TTslDebuga=class(TCustomControl)
|
|||
end
|
||||
return 0;
|
||||
end
|
||||
function dbgtooldorun(o,e);
|
||||
begin
|
||||
if not(FConnectchannel or FRemoteWait) then
|
||||
begin
|
||||
return CallMessgeFunction(frunbtncall,nil,nil);
|
||||
end
|
||||
//if not( FBtns["终止"].Visible) then return ;
|
||||
toolbtnState("继续");
|
||||
if FCurrentgotoitem and FCurrentgotoitem.FEditer then FCurrentgotoitem.FEditer.ExecuteCommand("ecruningto",nil);
|
||||
ExecuteCommand("dbgrun");
|
||||
{$ifdef linux}
|
||||
{$else}
|
||||
if not Fdebugedwhandle then
|
||||
Fdebugedwhandle := GetWindowHandleByPID(_wapi.GetProcessId(FDebughandle),_wapi);
|
||||
if Fdebugedwhandle then
|
||||
begin
|
||||
_wapi.SetForegroundWindow(Fdebugedwhandle);
|
||||
end
|
||||
{$endif}
|
||||
end
|
||||
function Dbgtooldo(o,e)
|
||||
begin
|
||||
cp := o.Caption;
|
||||
|
|
@ -792,24 +820,7 @@ type TTslDebuga=class(TCustomControl)
|
|||
end
|
||||
"继续":
|
||||
begin
|
||||
if not(FConnectchannel or FRemoteWait) then
|
||||
begin
|
||||
|
||||
//return MessageboxA("正在调试中","提示",0,self.Handle);
|
||||
return CallMessgeFunction(frunbtncall,nil,nil);
|
||||
end
|
||||
toolbtnState("继续");
|
||||
if FCurrentgotoitem and FCurrentgotoitem.FEditer then FCurrentgotoitem.FEditer.ExecuteCommand("ecruningto",nil);
|
||||
ExecuteCommand("dbgrun");
|
||||
{$ifdef linux}
|
||||
{$else}
|
||||
if not Fdebugedwhandle then
|
||||
Fdebugedwhandle := GetWindowHandleByPID(_wapi.GetProcessId(FDebughandle),_wapi);
|
||||
if Fdebugedwhandle then
|
||||
begin
|
||||
_wapi.SetForegroundWindow(Fdebugedwhandle);
|
||||
end
|
||||
{$endif}
|
||||
dbgtooldorun(o,e);
|
||||
end
|
||||
"终止":
|
||||
begin
|
||||
|
|
@ -1498,8 +1509,8 @@ type TTslDebuga=class(TCustomControl)
|
|||
begin
|
||||
for i,v in FBtns do
|
||||
begin
|
||||
if v.Caption="添加/删除断点F5" then continue;
|
||||
if v.Caption="继续" then continue;
|
||||
if i="添加/删除断点F5" then continue;
|
||||
if i="继续" then continue;
|
||||
v.Visible := false;
|
||||
end
|
||||
//FToolbar.Visible := false;
|
||||
|
|
|
|||
Loading…
Reference in New Issue