更新动态库 以及界面库

This commit is contained in:
2024-08-07 17:02:46 +08:00
parent 2fd9816b7e
commit 18c5435bf6
21 changed files with 72 additions and 17 deletions
+11
View File
@@ -4,8 +4,18 @@
uses tslvcl,utslvclDesigner;
deletefuncacheini();
isdebug := false;
willopen := "";
for i:= 0 to sysparamcount() do
begin
if wait_filename then
begin
willopen := sysparamstr(i);
wait_filename := 0;
end else
if ("-tpj"=sysparamstr(i)) then
begin
wait_filename := true;
end else
if ("-DEBUGSERVER" = sysparamstr(i)) then
begin
isdebug := true;
@@ -20,6 +30,7 @@ end
app := InitializeApplication();
app.createform(class(TVclDesignerStart),Desginer);
Desginer.Show();
if willopen then Desginer.OpenFileFromTpjFile(willopen);
r := app.run();
return r;
type TVclDesignerStart = class(TVclDesigner) //实现唯一的窗口
+20 -2
View File
@@ -366,11 +366,13 @@ type teditorform = class(TVCform) //
begin
it.caption := v;
ite := new TMenu(self);
ite.caption := c_m_editor;
ite.Checked := true;
ite.caption := c_m_editor;
ite.Parent := it;
itb := new TMenu(self);
itb.caption := c_m_exer;
global g_debug_chooser;
g_debug_chooser := c_m_exer;
itb.Checked := true;
itb.Parent := it;
itb._tag := ite;
ite._tag := itb;
@@ -1390,7 +1392,13 @@ type tsearchdir = class(TCustomControl)
function Create(AOwner);override;
begin
inherited;
fcopyer := new TClipBoard(self);
caption := "函数搜索目录:左侧为别名,右侧为-libpath目录....";
fcpmenu := new TPopupmenu(self);
mui := new TMenu(self);
mui.caption := "复制目录";
mui.Parent := fcpmenu;
mui.OnClick := thisfunction(copy_current_dirs);
WsDlgModalFrame := true;
WSSizebox := true;
visible := false;
@@ -1413,6 +1421,10 @@ type tsearchdir = class(TCustomControl)
ls.Border := true;
FLists[i] := ls;
end
FLists[0].PopupMenu := fcpmenu;
FLists[0].OnPopupMenu := function(o,e)begin
if o.ItemIndex<0 then return e.skip;
end
btrecs := array(
array(124,3,144,25),
array(124,206,144,230),
@@ -1446,6 +1458,10 @@ type tsearchdir = class(TCustomControl)
o.endmodal(0);
end ;
end
function copy_current_dirs(o,e);
begin
fcopyer.text := array2str(FLists[1].items,";");
end
function editkeyup(o,e);
begin
if e.CharCode = 13 then
@@ -1608,6 +1624,8 @@ type tsearchdir = class(TCustomControl)
FEdit;
FLists;
FBtns;
fcpmenu;
fcopyer;
end
private
function GetIcon();
+6 -1
View File
@@ -4265,7 +4265,12 @@ type TEditer=class(TCustomcontrol) //
ft := str2array(ft,";");
end
if not ft then ft := array("*");
FindFiles(dir,ft,d["c_dir"],r);
for i,v in str2array(dir,";") do //多目录查找
begin
tv := trim(v);
if tv then
FindFiles(tv,ft,d["c_dir"],r);
end
return r;
end
function FindFiles(dir,ft,sub,ret);
+5 -1
View File
@@ -2206,13 +2206,17 @@ type TTsfFileParser = class() //
function ParserFiles(dir,FFileNames,mf);
begin
dirs := FileList("",dir+fiofs+"*");
for i,v in dirs do
for i,v in dirs do //解析文件
begin
fn := v["FileName"] ;
if not(pos("D",v["Attr"])) and (1=ParseRegExpr("\\.tsf$",fn,"i",m,mp,ml)) then //tsf文件处理
begin
parserafile(dir,v);
end
end
for i,v in dirs do //解析目录
begin
fn := v["FileName"] ;
if pos("D",v["Attr"]) and not( fn in array(".","..")) then //子目录查找
begin
ParserFiles(dir+fiofs+fn,FFileNames,mf);
+3 -2
View File
@@ -1425,12 +1425,13 @@ type TTslDebuga=class(TCustomControl)
cnn := "";
for ii := 1 to length(cn) do
begin
if cn[ii]in array(".",":")then
cni := cn[ii];
if (cni = ".") or (cni = ":")then
begin
cn := cnn;
break;
end
cnn += cn[ii];
cnn += cni;
end
f := FDebugtsfs[lowercase(cn)];
if not f then
+13 -11
View File
@@ -318,21 +318,23 @@ type TVclDesigner = class(tvcform)
public //设计器工程
ffilemenu;
fviewmenu;
function OpenFileFromTpjFile(); //从文件打开工程
function OpenFileFromTpjFile(f); //从文件打开工程
begin
FProjectFileOpener.caption := "打开";
if FProjectFileOpener.OpenDlg() then
if not(ifstring(f)) and FProjectFileOpener.OpenDlg() then
begin
f := FProjectFileOpener.FileName;
FProjectsManager.OpenFileFromTpjFile(f);
fio := ioFileseparator();
for i := length(f) downto 2 do
f := FProjectFileOpener.FileName;
end
if not fileexists("",f) then return ;
FProjectsManager.OpenFileFromTpjFile(f);
fio := ioFileseparator();
for i := length(f) downto 2 do
begin
if f[i]=fio then
begin
if f[i]=fio then
begin
FProjectFileOpener.initialDir := f[1:(i-1)];
break;
end
FProjectFileOpener.initialDir := f[1:(i-1)];
break;
end
end
end