243 lines
23 KiB
Plaintext
243 lines
23 KiB
Plaintext
|
<!DOCTYPE html>
|
||
|
<html lang="en">
|
||
|
<head>
|
||
|
<meta charset="UTF-8">
|
||
|
<meta name="generator" content="TempleOS V5.03">
|
||
|
<meta name="viewport" content="width=device-width">
|
||
|
<link rel="stylesheet" href="/style/templeos.css">
|
||
|
<script src="/script/templeos.js"></script>
|
||
|
<style type="text/css">
|
||
|
.cF0{color:#000000;background-color:#ffffff;}
|
||
|
.cF1{color:#0000aa;background-color:#ffffff;}
|
||
|
.cF2{color:#00aa00;background-color:#ffffff;}
|
||
|
.cF3{color:#00aaaa;background-color:#ffffff;}
|
||
|
.cF4{color:#aa0000;background-color:#ffffff;}
|
||
|
.cF5{color:#aa00aa;background-color:#ffffff;}
|
||
|
.cF6{color:#aa5500;background-color:#ffffff;}
|
||
|
.cF7{color:#aaaaaa;background-color:#ffffff;}
|
||
|
.cF8{color:#555555;background-color:#ffffff;}
|
||
|
.cF9{color:#5555ff;background-color:#ffffff;}
|
||
|
.cFA{color:#55ff55;background-color:#ffffff;}
|
||
|
.cFB{color:#55ffff;background-color:#ffffff;}
|
||
|
.cFC{color:#ff5555;background-color:#ffffff;}
|
||
|
.cFD{color:#ff55ff;background-color:#ffffff;}
|
||
|
.cFE{color:#ffff55;background-color:#ffffff;}
|
||
|
.cFF{color:#ffffff;background-color:#ffffff;}
|
||
|
</style>
|
||
|
</head>
|
||
|
<body>
|
||
|
<pre id="content">
|
||
|
<a name="l1"></a><span class=cF0>#</span><span class=cF1>help_index</span><span class=cF0> </span><span class=cF6>"DolDoc/Misc"</span><span class=cF0>
|
||
|
<a name="l2"></a>
|
||
|
<a name="l3"></a></span><span class=cF1>U8</span><span class=cF0> </span><span class=cFB>captured_macro_name</span><span class=cF0>[</span><span class=cF3>STR_LEN</span><span class=cF0>];
|
||
|
<a name="l4"></a></span><span class=cF5>StrCpy</span><span class=cF0>(</span><span class=cFB>captured_macro_name</span><span class=cF0>,</span><span class=cF6>"Test"</span><span class=cF0>);
|
||
|
<a name="l5"></a>
|
||
|
<a name="l6"></a></span><span class=cF9>I64</span><span class=cF0> </span><span class=cFB>sys_macro_repeat_n</span><span class=cF0>=1;
|
||
|
<a name="l7"></a>
|
||
|
<a name="l8"></a></span><span class=cF1>U0</span><span class=cF0> </span><span class=cF5>SysMacroStripKey</span><span class=cF0>(</span><span class=cF9>CJob</span><span class=cF0> *macro_head,</span><span class=cF9>I64</span><span class=cF0> arg1,</span><span class=cF9>I64</span><span class=cF0> arg2)
|
||
|
<a name="l9"></a>{
|
||
|
<a name="l10"></a> </span><span class=cF9>CJob</span><span class=cF0> *tmpc,*tmpc1;
|
||
|
<a name="l11"></a> tmpc=macro_head->next;
|
||
|
<a name="l12"></a> </span><span class=cF1>while</span><span class=cF0> (tmpc!=macro_head) </span><span class=cF7>{</span><span class=cF0>
|
||
|
<a name="l13"></a> tmpc1=tmpc->next;
|
||
|
<a name="l14"></a> </span><span class=cF1>if</span><span class=cF0> (tmpc->job_code==</span><span class=cF3>JOBT_MSG</span><span class=cF0> &&
|
||
|
<a name="l15"></a> </span><span class=cF7>(</span><span class=cF0>tmpc->msg_code==</span><span class=cF3>MSG_KEY_DOWN</span><span class=cF0> || tmpc->msg_code==</span><span class=cF3>MSG_KEY_UP</span><span class=cF0> ||
|
||
|
<a name="l16"></a> tmpc->msg_code==</span><span class=cF3>MSG_KEY_DOWN_UP</span><span class=cF7>)</span><span class=cF0> &&
|
||
|
<a name="l17"></a> arg1 && tmpc->aux1==arg1 || !arg1 && tmpc->aux2==arg2) {
|
||
|
<a name="l18"></a> </span><span class=cF5>QueRem</span><span class=cF0>(tmpc);
|
||
|
<a name="l19"></a> </span><span class=cF5>JobDel</span><span class=cF0>(tmpc);
|
||
|
<a name="l20"></a> }
|
||
|
<a name="l21"></a> tmpc=tmpc1;
|
||
|
<a name="l22"></a> </span><span class=cF7>}</span><span class=cF0>
|
||
|
<a name="l23"></a>}
|
||
|
<a name="l24"></a>
|
||
|
<a name="l25"></a>#</span><span class=cF1>define</span><span class=cF0> </span><span class=cF3>MT_NULL</span><span class=cF0> 0
|
||
|
<a name="l26"></a>#</span><span class=cF1>define</span><span class=cF0> </span><span class=cF3>MT_MSG</span><span class=cF0> 1
|
||
|
<a name="l27"></a>#</span><span class=cF1>define</span><span class=cF0> </span><span class=cF3>MT_CHAR</span><span class=cF0> 2
|
||
|
<a name="l28"></a>
|
||
|
<a name="l29"></a></span><span class=cF1>class</span><span class=cF0> </span><span class=cF9>CMacroTmp</span><span class=cF0>
|
||
|
<a name="l30"></a>{
|
||
|
<a name="l31"></a> </span><span class=cF9>CMacroTmp</span><span class=cF0> *next,*last;
|
||
|
<a name="l32"></a> </span><span class=cF9>I64</span><span class=cF0> type;
|
||
|
<a name="l33"></a> </span><span class=cF1>U8</span><span class=cF0> buf[</span><span class=cF3>STR_LEN</span><span class=cF0>];
|
||
|
<a name="l34"></a>};
|
||
|
<a name="l35"></a>
|
||
|
<a name="l36"></a></span><span class=cF9>CMacroTmp</span><span class=cF0> *</span><span class=cF5>Cmd2MT</span><span class=cF0>(</span><span class=cF9>CJob</span><span class=cF0> *tmpc)
|
||
|
<a name="l37"></a>{
|
||
|
<a name="l38"></a> </span><span class=cF1>U8</span><span class=cF0> buf[8];
|
||
|
<a name="l39"></a> </span><span class=cF9>CMacroTmp</span><span class=cF0> *tmpmt=</span><span class=cF5>CAlloc</span><span class=cF0>(</span><span class=cF1>sizeof</span><span class=cF7>(</span><span class=cF9>CMacroTmp</span><span class=cF7>)</span><span class=cF0>);
|
||
|
<a name="l40"></a> </span><span class=cF1>if</span><span class=cF0> (</span><span class=cF5>Bt</span><span class=cF7>(</span><span class=cFB>char_bmp_macro</span><span class=cF0>,tmpc->aux1</span><span class=cF7>)</span><span class=cF0> && tmpc->msg_code==</span><span class=cF3>MSG_KEY_DOWN</span><span class=cF0>) </span><span class=cF7>{</span><span class=cF0>
|
||
|
<a name="l41"></a> tmpmt->type=</span><span class=cF3>MT_CHAR</span><span class=cF0>;
|
||
|
<a name="l42"></a> buf[0]=tmpc->aux1;
|
||
|
<a name="l43"></a> buf[1]=0;
|
||
|
<a name="l44"></a> </span><span class=cF5>StrPrint</span><span class=cF0>(tmpmt->buf,</span><span class=cF6>"%Q"</span><span class=cF0>,buf);
|
||
|
<a name="l45"></a> </span><span class=cF7>}</span><span class=cF0> </span><span class=cF1>else</span><span class=cF0> </span><span class=cF7>{</span><span class=cF0>
|
||
|
<a name="l46"></a> tmpmt->type=</span><span class=cF3>MT_MSG</span><span class=cF0>;
|
||
|
<a name="l47"></a> </span><span class=cF5>StrPrint</span><span class=cF0>(tmpmt->buf,</span><span class=cF6>"Msg(0x%X,0x%X,0x%X);"</span><span class=cF0>,
|
||
|
<a name="l48"></a> tmpc->msg_code,tmpc->aux1,tmpc->aux2);
|
||
|
<a name="l49"></a> </span><span class=cF7>}</span><span class=cF0>
|
||
|
<a name="l50"></a> </span><span class=cF1>return</span><span class=cF0> tmpmt;
|
||
|
<a name="l51"></a>}
|
||
|
<a name="l52"></a>
|
||
|
<a name="l53"></a></span><span class=cF1>U8</span><span class=cF0> *</span><span class=cF5>SysMacro2Str</span><span class=cF0>(</span><span class=cF9>CJob</span><span class=cF0> *macro_head)
|
||
|
<a name="l54"></a>{
|
||
|
<a name="l55"></a> </span><span class=cF9>CJob</span><span class=cF0> *tmpc;
|
||
|
<a name="l56"></a> </span><span class=cF9>I64</span><span class=cF0> cnt=1; </span><span class=cF2>//terminating zero</span><span class=cF0>
|
||
|
<a name="l57"></a> </span><span class=cF1>U8</span><span class=cF0> *ptr,*m;
|
||
|
<a name="l58"></a> </span><span class=cF9>CMacroTmp</span><span class=cF0> *tmpmt,*tmpmt1,head;
|
||
|
<a name="l59"></a> </span><span class=cF5>LBtr</span><span class=cF0>(&</span><span class=cFB>sys_semas</span><span class=cF0>[</span><span class=cF3>SEMA_RECORD_MACRO</span><span class=cF0>],0);
|
||
|
<a name="l60"></a>
|
||
|
<a name="l61"></a> </span><span class=cF5>QueInit</span><span class=cF0>(&head);
|
||
|
<a name="l62"></a> head.type=</span><span class=cF3>MT_NULL</span><span class=cF0>;
|
||
|
<a name="l63"></a> tmpc=macro_head->next;
|
||
|
<a name="l64"></a> </span><span class=cF1>while</span><span class=cF0> (tmpc!=macro_head) </span><span class=cF7>{</span><span class=cF0>
|
||
|
<a name="l65"></a> tmpmt=</span><span class=cF5>Cmd2MT</span><span class=cF0>(tmpc);
|
||
|
<a name="l66"></a> </span><span class=cF5>QueIns</span><span class=cF0>(tmpmt,head.last);
|
||
|
<a name="l67"></a> cnt+=</span><span class=cF5>StrLen</span><span class=cF0>(tmpmt->buf);
|
||
|
<a name="l68"></a> </span><span class=cF1>if</span><span class=cF0> (tmpmt->type==</span><span class=cF3>MT_CHAR</span><span class=cF0>) {
|
||
|
<a name="l69"></a> </span><span class=cF1>if</span><span class=cF0> (tmpmt->last->type!=</span><span class=cF3>MT_CHAR</span><span class=cF0>)
|
||
|
<a name="l70"></a> cnt+=</span><span class=cF5>StrLen</span><span class=cF0>(</span><span class=cF6>"\""</span><span class=cF0>);
|
||
|
<a name="l71"></a> </span><span class=cF1>if</span><span class=cF0> (tmpmt->next->type!=</span><span class=cF3>MT_CHAR</span><span class=cF0>)
|
||
|
<a name="l72"></a> cnt+=</span><span class=cF5>StrLen</span><span class=cF0>(</span><span class=cF6>"\";"</span><span class=cF0>);
|
||
|
<a name="l73"></a> }
|
||
|
<a name="l74"></a> tmpc=tmpc->next;
|
||
|
<a name="l75"></a> </span><span class=cF7>}</span><span class=cF0>
|
||
|
<a name="l76"></a>
|
||
|
<a name="l77"></a> m=</span><span class=cF5>MAlloc</span><span class=cF0>(cnt);
|
||
|
<a name="l78"></a> ptr=m;
|
||
|
<a name="l79"></a>
|
||
|
<a name="l80"></a> tmpmt=head.next;
|
||
|
<a name="l81"></a> </span><span class=cF1>while</span><span class=cF0> (tmpmt!=&head) </span><span class=cF7>{</span><span class=cF0>
|
||
|
<a name="l82"></a> tmpmt1=tmpmt->next;
|
||
|
<a name="l83"></a> </span><span class=cF1>if</span><span class=cF0> (tmpmt->type==</span><span class=cF3>MT_MSG</span><span class=cF0>) {
|
||
|
<a name="l84"></a> </span><span class=cF5>StrCpy</span><span class=cF0>(ptr, tmpmt->buf);
|
||
|
<a name="l85"></a> ptr+=</span><span class=cF5>StrLen</span><span class=cF0>(tmpmt->buf);
|
||
|
<a name="l86"></a> } </span><span class=cF1>else</span><span class=cF0> {
|
||
|
<a name="l87"></a> </span><span class=cF1>if</span><span class=cF0> (tmpmt->last->type!=</span><span class=cF3>MT_CHAR</span><span class=cF0>) </span><span class=cF7>{</span><span class=cF0>
|
||
|
<a name="l88"></a> </span><span class=cF5>StrCpy</span><span class=cF0>(ptr, </span><span class=cF6>"\""</span><span class=cF0>);
|
||
|
<a name="l89"></a> ptr+=</span><span class=cF5>StrLen</span><span class=cF0>(</span><span class=cF6>"\""</span><span class=cF0>);
|
||
|
<a name="l90"></a> </span><span class=cF7>}</span><span class=cF0>
|
||
|
<a name="l91"></a> </span><span class=cF5>StrCpy</span><span class=cF0>(ptr,tmpmt->buf);
|
||
|
<a name="l92"></a> ptr+=</span><span class=cF5>StrLen</span><span class=cF0>(tmpmt->buf);
|
||
|
<a name="l93"></a> </span><span class=cF1>if</span><span class=cF0> (tmpmt->next->type!=</span><span class=cF3>MT_CHAR</span><span class=cF0>) </span><span class=cF7>{</span><span class=cF0>
|
||
|
<a name="l94"></a> </span><span class=cF5>StrCpy</span><span class=cF0>(ptr, </span><span class=cF6>"\";"</span><span class=cF0>);
|
||
|
<a name="l95"></a> ptr+=</span><span class=cF5>StrLen</span><span class=cF0>(</span><span class=cF6>"\";"</span><span class=cF0>);
|
||
|
<a name="l96"></a> </span><span class=cF7>}</span><span class=cF0>
|
||
|
<a name="l97"></a> }
|
||
|
<a name="l98"></a> </span><span class=cF5>Free</span><span class=cF0>(tmpmt);
|
||
|
<a name="l99"></a> tmpmt=tmpmt1;
|
||
|
<a name="l100"></a> </span><span class=cF7>}</span><span class=cF0>
|
||
|
<a name="l101"></a> *ptr=0;
|
||
|
<a name="l102"></a> </span><span class=cF1>return</span><span class=cF0> m;
|
||
|
<a name="l103"></a>}
|
||
|
<a name="l104"></a>
|
||
|
<a name="l105"></a></span><span class=cF1>U0</span><span class=cF0> </span><span class=cF5>PlaySysMacro</span><span class=cF0>(</span><span class=cF9>I64</span><span class=cF0> n=1)
|
||
|
<a name="l106"></a>{
|
||
|
<a name="l107"></a> </span><span class=cF9>CTask</span><span class=cF0> *task=</span><span class=cFB>sys_focus_task</span><span class=cF0>;
|
||
|
<a name="l108"></a> </span><span class=cF1>U8</span><span class=cF0> *m;
|
||
|
<a name="l109"></a> </span><span class=cF1>if</span><span class=cF0> (</span><span class=cF5>TaskValidate</span><span class=cF7>(</span><span class=cF0>task</span><span class=cF7>)</span><span class=cF0>) </span><span class=cF7>{</span><span class=cF0>
|
||
|
<a name="l110"></a> </span><span class=cF5>LBtr</span><span class=cF0>(&</span><span class=cFB>sys_semas</span><span class=cF0>[</span><span class=cF3>SEMA_RECORD_MACRO</span><span class=cF0>],0);
|
||
|
<a name="l111"></a> m=</span><span class=cF5>SysMacro2Str</span><span class=cF0>(&</span><span class=cFB>sys_macro_head</span><span class=cF0>);
|
||
|
<a name="l112"></a> </span><span class=cF1>while</span><span class=cF0> (n-- && </span><span class=cF5>TaskValidate</span><span class=cF7>(</span><span class=cF0>task</span><span class=cF7>)</span><span class=cF0>) {
|
||
|
<a name="l113"></a> </span><span class=cF1>if</span><span class=cF0> (task==</span><span class=cF5>Fs</span><span class=cF0>)
|
||
|
<a name="l114"></a> </span><span class=cF5>InStr</span><span class=cF0>(</span><span class=cF6>"%s"</span><span class=cF0>,m);
|
||
|
<a name="l115"></a> </span><span class=cF1>else</span><span class=cF0>
|
||
|
<a name="l116"></a> </span><span class=cF5>XTalkStrWait</span><span class=cF0>(task,</span><span class=cF6>"%s"</span><span class=cF0>,m);
|
||
|
<a name="l117"></a> }
|
||
|
<a name="l118"></a> </span><span class=cF5>Free</span><span class=cF0>(m);
|
||
|
<a name="l119"></a> </span><span class=cF7>}</span><span class=cF0>
|
||
|
<a name="l120"></a>}
|
||
|
<a name="l121"></a>
|
||
|
<a name="l122"></a></span><span class=cF1>U0</span><span class=cF0> </span><span class=cF5>EdInsCapturedMacro</span><span class=cF0>()
|
||
|
<a name="l123"></a>{
|
||
|
<a name="l124"></a> </span><span class=cF1>U8</span><span class=cF0> *st=</span><span class=cF5>SysMacro2Str</span><span class=cF0>(&</span><span class=cFB>sys_macro_head</span><span class=cF0>);
|
||
|
<a name="l125"></a> </span><span class=cF1>if</span><span class=cF0> (</span><span class=cFB>sys_focus_task</span><span class=cF0>) </span><span class=cF7>{</span><span class=cF0>
|
||
|
<a name="l126"></a> </span><span class=cF5>XTalk</span><span class=cF0>(</span><span class=cFB>sys_focus_task</span><span class=cF0>,</span><span class=cF6>"$MA+LIS,T=\"%s\",LM=\"%$Q\"$"</span><span class=cF0>,
|
||
|
<a name="l127"></a> </span><span class=cFB>captured_macro_name</span><span class=cF0>,st);
|
||
|
<a name="l128"></a> </span><span class=cF5>Free</span><span class=cF0>(st);
|
||
|
<a name="l129"></a> </span><span class=cF7>}</span><span class=cF0>
|
||
|
<a name="l130"></a>}
|
||
|
<a name="l131"></a>
|
||
|
<a name="l132"></a>#</span><span class=cF1>define</span><span class=cF0> </span><span class=cF3>SM_RECORD</span><span class=cF0> 0
|
||
|
<a name="l133"></a>#</span><span class=cF1>define</span><span class=cF0> </span><span class=cF3>SM_INS</span><span class=cF0> 1
|
||
|
<a name="l134"></a>#</span><span class=cF1>define</span><span class=cF0> </span><span class=cF3>SM_PLAY</span><span class=cF0> 2
|
||
|
<a name="l135"></a>#</span><span class=cF1>define</span><span class=cF0> </span><span class=cF3>SM_REPEAT_N</span><span class=cF0> 3
|
||
|
<a name="l136"></a>#</span><span class=cF1>define</span><span class=cF0> </span><span class=cF3>SM_STOP</span><span class=cF0> 4
|
||
|
<a name="l137"></a>
|
||
|
<a name="l138"></a></span><span class=cF9>I64</span><span class=cF0> </span><span class=cF5>PopUpMacroMenu</span><span class=cF0>()
|
||
|
<a name="l139"></a>{
|
||
|
<a name="l140"></a> </span><span class=cF9>I64</span><span class=cF0> res=0;
|
||
|
<a name="l141"></a> </span><span class=cF1>U8</span><span class=cF0> buf[</span><span class=cF3>STR_LEN</span><span class=cF0>];
|
||
|
<a name="l142"></a> </span><span class=cF9>CJob</span><span class=cF0> *tmpc;
|
||
|
<a name="l143"></a> </span><span class=cF9>CDoc</span><span class=cF0> *doc=</span><span class=cF5>DocNew</span><span class=cF0>;
|
||
|
<a name="l144"></a> </span><span class=cF9>CDocEntry</span><span class=cF0> *doc_e=</span><span class=cF5>DocPrint</span><span class=cF0>(doc,</span><span class=cF6>"$DA-P,LEN=STR_LEN-1,A=\"Name:%%s\"$"</span><span class=cF0>);
|
||
|
<a name="l145"></a> doc_e->data=</span><span class=cFB>captured_macro_name</span><span class=cF0>;
|
||
|
<a name="l146"></a> </span><span class=cF5>DocDataFmt</span><span class=cF0>(doc,doc_e);
|
||
|
<a name="l147"></a>
|
||
|
<a name="l148"></a> doc_e=</span><span class=cF5>DocPrint</span><span class=cF0>(doc,</span><span class=cF6>"\n$DA,A=\"Repeat N:%%d\"$"</span><span class=cF0>);
|
||
|
<a name="l149"></a> doc_e->data=&</span><span class=cFB>sys_macro_repeat_n</span><span class=cF0>;
|
||
|
<a name="l150"></a> </span><span class=cF5>DocDataFmt</span><span class=cF0>(doc,doc_e);
|
||
|
<a name="l151"></a>
|
||
|
<a name="l152"></a> </span><span class=cF5>DocPrint</span><span class=cF0>(doc,</span><span class=cF6>"\n"</span><span class=cF0>
|
||
|
<a name="l153"></a> </span><span class=cF6>"$CM+LX,1,3$$BT,\"RECORD\",LE=SM_RECORD$"</span><span class=cF0>
|
||
|
<a name="l154"></a> </span><span class=cF6>"$CM+LX,17,0$$BT,\"INSERT\",LE=SM_INS$"</span><span class=cF0>
|
||
|
<a name="l155"></a> </span><span class=cF6>"$CM+LX,1,3$$BT,\"PLAY\",LE=SM_PLAY$"</span><span class=cF0>
|
||
|
<a name="l156"></a> </span><span class=cF6>"$CM+LX,17,0$$BT,\"REPEAT N\",LE=SM_REPEAT_N$"</span><span class=cF0>
|
||
|
<a name="l157"></a> </span><span class=cF6>"$CM+LX,1,3$$BT,\"STOP\",LE=SM_STOP$"</span><span class=cF0>
|
||
|
<a name="l158"></a> </span><span class=cF6>"$CM+LX,17,0$$BT,\"CANCEL\",LE=DOCM_CANCEL$"</span><span class=cF0>
|
||
|
<a name="l159"></a> </span><span class=cF6>"\n\n\n$GREEN$SHIFT-F2$FG$ will play macro.\n"</span><span class=cF0>);
|
||
|
<a name="l160"></a> doc->flags|=</span><span class=cF3>DOCF_SIZE_MIN</span><span class=cF0> | </span><span class=cF3>DOCF_FORM</span><span class=cF0>;
|
||
|
<a name="l161"></a> </span><span class=cF5>StrPrint</span><span class=cF0>(buf,</span><span class=cF6>"DocMenu(%d);"</span><span class=cF0>,doc);
|
||
|
<a name="l162"></a> </span><span class=cFB>sys_macro_task</span><span class=cF0>=</span><span class=cF5>Spawn</span><span class=cF0>(&</span><span class=cF5>SrvCmdLine</span><span class=cF0>,</span><span class=cF3>NULL</span><span class=cF0>,</span><span class=cF6>"Macro Popup"</span><span class=cF0>,,</span><span class=cF5>Fs</span><span class=cF0>);
|
||
|
<a name="l163"></a> </span><span class=cF5>Fs</span><span class=cF0>->popup_task=</span><span class=cFB>sys_macro_task</span><span class=cF0>;
|
||
|
<a name="l164"></a> </span><span class=cF5>LBts</span><span class=cF0>(&</span><span class=cFB>sys_macro_task</span><span class=cF0>->display_flags,</span><span class=cF3>DISPLAYf_WIN_ON_TOP</span><span class=cF0>);
|
||
|
<a name="l165"></a> tmpc=</span><span class=cF5>TaskExe</span><span class=cF0>(</span><span class=cFB>sys_macro_task</span><span class=cF0>,</span><span class=cF5>Fs</span><span class=cF0>,buf,
|
||
|
<a name="l166"></a> 1<<</span><span class=cF3>JOBf_WAKE_MASTER</span><span class=cF0>|1<<</span><span class=cF3>JOBf_FOCUS_MASTER</span><span class=cF0>);
|
||
|
<a name="l167"></a> </span><span class=cF5>JobResScan</span><span class=cF0>(tmpc,&res);
|
||
|
<a name="l168"></a> </span><span class=cF5>Fs</span><span class=cF0>->popup_task=</span><span class=cF3>NULL</span><span class=cF0>;
|
||
|
<a name="l169"></a> </span><span class=cF5>Kill</span><span class=cF0>(</span><span class=cFB>sys_macro_task</span><span class=cF0>);
|
||
|
<a name="l170"></a> </span><span class=cFB>sys_macro_task</span><span class=cF0>=</span><span class=cF3>NULL</span><span class=cF0>;
|
||
|
<a name="l171"></a> </span><span class=cF5>DocDataScan</span><span class=cF0>(doc,doc_e);
|
||
|
<a name="l172"></a> </span><span class=cF5>DocDel</span><span class=cF0>(doc);
|
||
|
<a name="l173"></a> </span><span class=cF1>return</span><span class=cF0> res;
|
||
|
<a name="l174"></a>}
|
||
|
<a name="l175"></a>
|
||
|
<a name="l176"></a></span><span class=cF1>U0</span><span class=cF0> </span><span class=cF5>MacroTask</span><span class=cF0>(</span><span class=cF9>I64</span><span class=cF0>)
|
||
|
<a name="l177"></a>{
|
||
|
<a name="l178"></a> </span><span class=cF9>I64</span><span class=cF0> i;
|
||
|
<a name="l179"></a> </span><span class=cF5>StrCpy</span><span class=cF0>(</span><span class=cFB>captured_macro_name</span><span class=cF0>,</span><span class=cF6>"Click Here"</span><span class=cF0>);
|
||
|
<a name="l180"></a> </span><span class=cFB>sys_macro_repeat_n</span><span class=cF0>=1;
|
||
|
<a name="l181"></a> </span><span class=cF1>do</span><span class=cF0> </span><span class=cF7>{</span><span class=cF0>
|
||
|
<a name="l182"></a> i=</span><span class=cF5>PopUpMacroMenu</span><span class=cF0>;
|
||
|
<a name="l183"></a> </span><span class=cF5>WinRefocus</span><span class=cF0>(</span><span class=cFB>sys_focus_task</span><span class=cF0>);
|
||
|
<a name="l184"></a> </span><span class=cF1>switch</span><span class=cF0> (i) {
|
||
|
<a name="l185"></a> </span><span class=cF1>case</span><span class=cF0> </span><span class=cF3>SM_RECORD</span><span class=cF0>:
|
||
|
<a name="l186"></a> </span><span class=cF5>LBtr</span><span class=cF0>(&</span><span class=cFB>sys_semas</span><span class=cF0>[</span><span class=cF3>SEMA_RECORD_MACRO</span><span class=cF0>],0);
|
||
|
<a name="l187"></a> </span><span class=cF5>QueDel</span><span class=cF0>(&</span><span class=cFB>sys_macro_head</span><span class=cF0>,</span><span class=cF3>TRUE</span><span class=cF0>);
|
||
|
<a name="l188"></a> </span><span class=cF5>LBts</span><span class=cF0>(&</span><span class=cFB>sys_semas</span><span class=cF0>[</span><span class=cF3>SEMA_RECORD_MACRO</span><span class=cF0>],0);
|
||
|
<a name="l189"></a> </span><span class=cF1>break</span><span class=cF0>;
|
||
|
<a name="l190"></a> </span><span class=cF1>case</span><span class=cF0> </span><span class=cF3>SM_PLAY</span><span class=cF0>:
|
||
|
<a name="l191"></a> </span><span class=cF5>PlaySysMacro</span><span class=cF0>;
|
||
|
<a name="l192"></a> </span><span class=cF1>break</span><span class=cF0>;
|
||
|
<a name="l193"></a> </span><span class=cF1>case</span><span class=cF0> </span><span class=cF3>SM_REPEAT_N</span><span class=cF0>:
|
||
|
<a name="l194"></a> </span><span class=cF5>PlaySysMacro</span><span class=cF0>(</span><span class=cFB>sys_macro_repeat_n</span><span class=cF0>);
|
||
|
<a name="l195"></a> </span><span class=cF1>break</span><span class=cF0>;
|
||
|
<a name="l196"></a> </span><span class=cF1>case</span><span class=cF0> </span><span class=cF3>SM_STOP</span><span class=cF0>:
|
||
|
<a name="l197"></a> </span><span class=cF5>LBtr</span><span class=cF0>(&</span><span class=cFB>sys_semas</span><span class=cF0>[</span><span class=cF3>SEMA_RECORD_MACRO</span><span class=cF0>],0);
|
||
|
<a name="l198"></a> </span><span class=cF1>break</span><span class=cF0>;
|
||
|
<a name="l199"></a> </span><span class=cF1>case</span><span class=cF0> </span><span class=cF3>SM_INS</span><span class=cF0>:
|
||
|
<a name="l200"></a> </span><span class=cF5>LBtr</span><span class=cF0>(&</span><span class=cFB>sys_semas</span><span class=cF0>[</span><span class=cF3>SEMA_RECORD_MACRO</span><span class=cF0>],0);
|
||
|
<a name="l201"></a> </span><span class=cF5>EdInsCapturedMacro</span><span class=cF0>;
|
||
|
<a name="l202"></a> </span><span class=cF1>break</span><span class=cF0>;
|
||
|
<a name="l203"></a> }
|
||
|
<a name="l204"></a> </span><span class=cF7>}</span><span class=cF0> </span><span class=cF1>while</span><span class=cF0> (i>=0);
|
||
|
<a name="l205"></a>}
|
||
|
<a name="l206"></a>
|
||
|
<a name="l207"></a></span><span class=cF1>U0</span><span class=cF0> </span><span class=cF5>EdMacroUtil</span><span class=cF0>()
|
||
|
<a name="l208"></a>{
|
||
|
<a name="l209"></a> </span><span class=cF1>if</span><span class=cF0> (!</span><span class=cFB>sys_macro_task</span><span class=cF0>)
|
||
|
<a name="l210"></a> </span><span class=cF5>Spawn</span><span class=cF0>(&</span><span class=cF5>MacroTask</span><span class=cF0>,</span><span class=cF3>NULL</span><span class=cF0>,</span><span class=cF6>"Macro"</span><span class=cF0>);
|
||
|
<a name="l211"></a>}
|
||
|
</span></pre></body>
|
||
|
</html>
|