Вверх ↑
Ответов: 286
Рейтинг: 25
#1: 2021-12-22 11:54:01 ЛС | профиль | цитата
Вот так?

Add(MainForm,2953706,21,105)
{
Width=585
Height=442
}
Add(InlineCode,11553839,280,301)
{
WorkPoints=#7:doFanOn|8:doFanOff|
Code=#0:|15:unit HiAsmUnit;|0:|9:interface|0:|21:uses kol,Share,Debug;|0:|4:type|28: THiAsmClass = class(TDebug)|10: private|8: |10: public|20: onFanon: THI_Event;|21: onFanoff: THI_Event;|3: |50: Procedure doFanOn(var _Data:TData; Index:Word); |50: Procedure doFanOff(var _Data:TData; Index:Word);|5: end;|69:Procedure on(); stdcall; external AcerFanControlLib.dll name '_on@0';|71:Procedure off(); stdcall; external AcerFanControlLib.dll name '_off@0';|2: |15: implementation|3: |30:Procedure THiAsmClass.doFanOn;|5:begin|4: on;|32: _hi_OnEvent(onFanon,'Yes') ;|4:end;|0:|31:Procedure THiAsmClass.doFanOff;|5:begin|5: off;|33: _hi_OnEvent(onFanoff,'Yes') ;|4:end;|4:end.|
}
Add(Button,5892096,203,294)
{
Left=200
Top=290
link(onClick,11553839:doFanOn,[(257,300)(257,307)])
}
Add(Button,9461849,196,350)
{
Left=195
Top=350
link(onClick,11553839:doFanOff,[(254,356)(254,314)])
}

карма: 2
0