Latest post of the previous page:
Code: Select all
DX=4
transform=
[win.Uuid"fcef11c4-5490-451d-8b4a-62fa03f52759"]: {1,3,11} --copy
[win.Uuid"502d00df-ee31-41cf-9028-442d2e352990"]: {1,3,11} --copy only current
[win.Uuid"431a2f37-ac01-4ecd-bb6f-8cde584e5a03"]: {1,3,11} --move
[win.Uuid"89664ef4-bb8c-4932-a8c0-59cafd937aba"]: {1,3,11} --move only current
[win.Uuid"fad00dbe-3fff-4095-9232-e1cc70c67737"]: {1,3,6,8} --mkdir
[win.Uuid"5eb266f4-980d-46af-b3d2-2c50e64bca81"]: {1,3,11} --link
[win.Uuid"1d07cee2-8f4f-480a-be93-069b4ff59a2b"]: {1,3,6} --new
[win.Uuid"8c9ead29-910f-4b24-a669-edafba6ed964"]: {1,3,6,7,9,15.1,16.1,17.1,18.1,20.1,22.2,23.1} --findfile
[win.Uuid"5d3cba90-f32d-433c-b016-9bb4af96facc"]: {1,2.3,3.3,5,7,12.1,13.1} --editsearch
[win.Uuid"8bccdffd-3b34-49f8-87cd-f4d885b75873"]: {1,2.3,3.3,5,7,12.1,13.1} --editreplace
[win.Uuid"9162f965-78b8-4476-98ac-d699e5b6afe7"]: {1,3,6} --saveas
[win.Uuid"fc4fd19a-43d2-4987-ac31-0f7a94901692"]: {1,3,5,7,9,11,13,15,17} --plugininformation
F=far.Flags
ConsoleWidth=->
rr=far.AdvControl"ACTL_GETFARRECT"
rr.Right-rr.Left+1
Event
group:"DialogEvent"
description:"always ignore"
action:(event,param)->
if event==F.DE_DLGPROCINIT and param.Msg==F.DN_INITDIALOG
id=far.SendDlgMessage param.hDlg,F.DM_GETDIALOGINFO
if id and transform[id.Id]
cx=ConsoleWidth!
{Left:dl,Top:dt,Right:dr,Bottom:db}=far.SendDlgMessage param.hDlg,F.DM_GETDLGRECT
diff=(cx-DX)-(dr-dl+1)
if diff>0
far.SendDlgMessage param.hDlg,F.DM_RESIZEDIALOG,0,{X:cx-DX,Y:db-dt+1}
far.SendDlgMessage param.hDlg,F.DM_MOVEDIALOG,1,{X:DX/2,Y:dt}
for ii in *transform[id.Id]
index,opt=math.modf ii
opt=math.floor(opt*10+0.5)
item=far.GetDlgItem param.hDlg,index
switch opt
when 0
item[4]+=diff
when 1
item[2]+=diff/2
when 2
item[4]+=diff/2
when 3
item[2]+=diff
far.SetDlgItem param.hDlg,index,item
false