templeos-info/public/Wb/Home/Src/Adam/WallPaper.HC.HTML

197 lines
22 KiB
HTML
Executable File

<!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>&quot;Windows&quot;</span><span class=cF0>
<a name="l2"></a>
<a name="l3"></a></span><span class=cF1>class</span><span class=cF0> </span><span class=cF9>CWallPaperGlbls</span><span class=cF0>
<a name="l4"></a>{
<a name="l5"></a> </span><span class=cF9>I64</span><span class=cF0> last_calc_idle_cnt,last_swap_cnter[</span><span class=cF3>MP_PROCESSORS_NUM</span><span class=cF0>];
<a name="l6"></a> </span><span class=cF1>F64</span><span class=cF0> last_calc_idle_delta_time;
<a name="l7"></a> </span><span class=cF1>U8</span><span class=cF0> top_line[</span><span class=cF3>STR_LEN</span><span class=cF0>];
<a name="l8"></a>} *</span><span class=cFB>wall</span><span class=cF0>=</span><span class=cF5>CAlloc</span><span class=cF0>(</span><span class=cF1>sizeof</span><span class=cF7>(</span><span class=cF9>CWallPaperGlbls</span><span class=cF7>)</span><span class=cF0>);
<a name="l9"></a></span><span class=cFB>wall</span><span class=cF0>-&gt;last_calc_idle_delta_time=1.0;
<a name="l10"></a>
<a name="l11"></a></span><span class=cF1>class</span><span class=cF0> </span><span class=cF9>CTaskWallPaperData</span><span class=cF0>
<a name="l12"></a>{
<a name="l13"></a> </span><span class=cF9>I64</span><span class=cF0> alloced_u8s,used_u8s;
<a name="l14"></a> </span><span class=cF1>U8</span><span class=cF0> caller_stk[</span><span class=cF3>STR_LEN</span><span class=cF0>-$];
<a name="l15"></a>};
<a name="l16"></a>
<a name="l17"></a></span><span class=cF1>U0</span><span class=cF0> </span><span class=cF5>WallPaper</span><span class=cF0>(</span><span class=cF9>CTask</span><span class=cF0> *_task)
<a name="l18"></a>{
<a name="l19"></a> </span><span class=cF9>I64</span><span class=cF0> i,j,l=</span><span class=cF3>TEXT_ROWS</span><span class=cF0>-1;
<a name="l20"></a> </span><span class=cF9>CTask</span><span class=cF0> *task;
<a name="l21"></a> </span><span class=cF9>CTaskWallPaperData</span><span class=cF0> *wpd;
<a name="l22"></a> </span><span class=cF9>CHashTable</span><span class=cF0> *old_hash=</span><span class=cF5>Fs</span><span class=cF0>-&gt;hash_table;
<a name="l23"></a> </span><span class=cF9>CCPU</span><span class=cF0> *c;
<a name="l24"></a> </span><span class=cF9>CDateStruct</span><span class=cF0> ds;
<a name="l25"></a> </span><span class=cF1>U8</span><span class=cF0> *st;
<a name="l26"></a> _task-&gt;text_attr=</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>WHITE</span><span class=cF0>;
<a name="l27"></a> </span><span class=cF1>if</span><span class=cF0> (</span><span class=cFB>sys_data_bp</span><span class=cF0>) </span><span class=cF7>{</span><span class=cF0>
<a name="l28"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,0,l--,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>YELLOW</span><span class=cF0>,
<a name="l29"></a> </span><span class=cF6>&quot;%010X/%010X %010X/%010X%12td%12td%12td&quot;</span><span class=cF0>,
<a name="l30"></a> </span><span class=cFB>sys_data_bp</span><span class=cF0>-&gt;used_u8s,</span><span class=cFB>sys_data_bp</span><span class=cF0>-&gt;alloced_u8s,
<a name="l31"></a> </span><span class=cFB>sys_code_bp</span><span class=cF0>-&gt;used_u8s,</span><span class=cFB>sys_code_bp</span><span class=cF0>-&gt;alloced_u8s,
<a name="l32"></a> </span><span class=cFB>cmp</span><span class=cF0>.compiled_lines,</span><span class=cFB>blkdev</span><span class=cF0>.read_cnt,</span><span class=cFB>blkdev</span><span class=cF0>.write_cnt);
<a name="l33"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,0,l--,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>WHITE</span><span class=cF0>,
<a name="l34"></a> </span><span class=cF6>&quot;______Data_Heap______ ______Code_Heap______ &quot;</span><span class=cF0>
<a name="l35"></a> </span><span class=cF6>&quot;___Lines___ ___Reads___ __Writes___&quot;</span><span class=cF0>);
<a name="l36"></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="l37"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,0,l--,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>WHITE</span><span class=cF0>,
<a name="l38"></a> </span><span class=cF6>&quot;%010X/%010X%12td%12td%12td&quot;</span><span class=cF0>,
<a name="l39"></a> </span><span class=cFB>sys_code_bp</span><span class=cF0>-&gt;used_u8s,</span><span class=cFB>sys_code_bp</span><span class=cF0>-&gt;alloced_u8s,
<a name="l40"></a> </span><span class=cFB>cmp</span><span class=cF0>.compiled_lines,</span><span class=cFB>blkdev</span><span class=cF0>.read_cnt,</span><span class=cFB>blkdev</span><span class=cF0>.write_cnt);
<a name="l41"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,0,l--,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>WHITE</span><span class=cF0>,
<a name="l42"></a> </span><span class=cF6>&quot;____CodeData_Heap____ &quot;</span><span class=cF0>
<a name="l43"></a> </span><span class=cF6>&quot;___Lines___ ___Reads___ ___Writes__&quot;</span><span class=cF0>);
<a name="l44"></a> </span><span class=cF7>}</span><span class=cF0>
<a name="l45"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,0,l--,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>WHITE</span><span class=cF0>,</span><span class=cF6>&quot;ProgressBars:%016X %016X %016X %016X&quot;</span><span class=cF0>,
<a name="l46"></a> </span><span class=cFB>progress1</span><span class=cF0>,</span><span class=cFB>progress2</span><span class=cF0>,</span><span class=cFB>progress3</span><span class=cF0>,</span><span class=cFB>progress4</span><span class=cF0>);
<a name="l47"></a> </span><span class=cF1>for</span><span class=cF0> (i=0;i&lt;</span><span class=cFB>mp_cnt</span><span class=cF0>;i++) </span><span class=cF7>{</span><span class=cF0>
<a name="l48"></a> c=&amp;</span><span class=cFB>cpu_structs</span><span class=cF0>[i];
<a name="l49"></a> </span><span class=cF1>if</span><span class=cF0> (</span><span class=cFB>winmgr</span><span class=cF0>.t-&gt;calc_idle_cnt!=</span><span class=cFB>wall</span><span class=cF0>-&gt;last_calc_idle_cnt) {
<a name="l50"></a> </span><span class=cFB>wall</span><span class=cF0>-&gt;last_calc_idle_delta_time=</span><span class=cFB>winmgr</span><span class=cF0>.t-&gt;calc_idle_delta_time;
<a name="l51"></a> </span><span class=cFB>wall</span><span class=cF0>-&gt;last_swap_cnter[i]=</span><span class=cFB>winmgr</span><span class=cF0>.t-&gt;last_swap_cnter[i];
<a name="l52"></a> </span><span class=cFB>winmgr</span><span class=cF0>.t-&gt;last_swap_cnter[i]=c-&gt;swap_cnter;
<a name="l53"></a> }
<a name="l54"></a>
<a name="l55"></a> task=c-&gt;seth_task;
<a name="l56"></a> </span><span class=cF1>do</span><span class=cF0> {
<a name="l57"></a> wpd=&amp;task-&gt;wallpaper_data;
<a name="l58"></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=cF1>break</span><span class=cF0>;
<a name="l59"></a> </span><span class=cF1>if</span><span class=cF0> (!</span><span class=cF7>(</span><span class=cFB>winmgr</span><span class=cF0>.updates&amp;31</span><span class=cF7>)</span><span class=cF0>) </span><span class=cF7>{</span><span class=cF0>
<a name="l60"></a> </span><span class=cF1>if</span><span class=cF0> (c==</span><span class=cF5>Gs</span><span class=cF0>)
<a name="l61"></a> </span><span class=cF5>Fs</span><span class=cF0>-&gt;hash_table=task-&gt;hash_table;
<a name="l62"></a> </span><span class=cF1>else</span><span class=cF0> </span><span class=cF2>//precaution</span><span class=cF0>
<a name="l63"></a> </span><span class=cF5>Fs</span><span class=cF0>-&gt;hash_table=old_hash;
<a name="l64"></a> </span><span class=cF5>StrPrint</span><span class=cF0>(wpd-&gt;caller_stk,</span><span class=cF6>&quot; %-18tp %-18tp %-18tp %-18tp&quot;</span><span class=cF0>,
<a name="l65"></a> </span><span class=cF5>TaskCaller</span><span class=cF7>(</span><span class=cF0>task,0</span><span class=cF7>)</span><span class=cF0>,</span><span class=cF5>TaskCaller</span><span class=cF7>(</span><span class=cF0>task,1</span><span class=cF7>)</span><span class=cF0>,
<a name="l66"></a> </span><span class=cF5>TaskCaller</span><span class=cF7>(</span><span class=cF0>task,2</span><span class=cF7>)</span><span class=cF0>,</span><span class=cF5>TaskCaller</span><span class=cF7>(</span><span class=cF0>task,3</span><span class=cF7>)</span><span class=cF0>);
<a name="l67"></a> </span><span class=cF7>}</span><span class=cF0>
<a name="l68"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,0,l--,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>YELLOW</span><span class=cF0>,wpd-&gt;caller_stk);
<a name="l69"></a> j=</span><span class=cF5>UnusedStk</span><span class=cF0>(task);
<a name="l70"></a> </span><span class=cF1>if</span><span class=cF0> (j&lt;0)
<a name="l71"></a> </span><span class=cF5>Panic</span><span class=cF0>(</span><span class=cF6>&quot;Stk Overflow&quot;</span><span class=cF0>,task);
<a name="l72"></a> </span><span class=cF1>if</span><span class=cF0> (!</span><span class=cF7>(</span><span class=cFB>winmgr</span><span class=cF0>.updates&amp;31</span><span class=cF7>)</span><span class=cF0>) </span><span class=cF7>{</span><span class=cF0>
<a name="l73"></a> wpd-&gt;alloced_u8s=</span><span class=cF5>TaskMemAlloced</span><span class=cF0>(task);
<a name="l74"></a> wpd-&gt;used_u8s =</span><span class=cF5>TaskMemUsed</span><span class=cF0>(task);
<a name="l75"></a> </span><span class=cF7>}</span><span class=cF0>
<a name="l76"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,0,l--,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>BROWN</span><span class=cF0>,
<a name="l77"></a> </span><span class=cF6>&quot; %-18ts #%08X %010X %010X/%010X %04X:%02tX:%08X&quot;</span><span class=cF0>,
<a name="l78"></a> task-&gt;task_title,task,j,wpd-&gt;used_u8s,wpd-&gt;alloced_u8s,
<a name="l79"></a> task-&gt;task_flags,task-&gt;display_flags,task-&gt;win_inhibit);
<a name="l80"></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=cF1>break</span><span class=cF0>;
<a name="l81"></a> task=task-&gt;next_task;
<a name="l82"></a> } </span><span class=cF1>while</span><span class=cF0> (task!=c-&gt;seth_task);
<a name="l83"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,0,l--,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>WHITE</span><span class=cF0>,</span><span class=cF6>&quot;CPU%02X %2tf%% ContextSwaps/s:%9,d&quot;</span><span class=cF0>,i,
<a name="l84"></a> 100.0*</span><span class=cF7>(</span><span class=cF0>1.0-c-&gt;idle_factor</span><span class=cF7>)</span><span class=cF0>,</span><span class=cF5>ToI64</span><span class=cF7>(</span><span class=cF0>(</span><span class=cFB>winmgr</span><span class=cF0>.t-&gt;last_swap_cnter[i]
<a name="l85"></a> -</span><span class=cFB>wall</span><span class=cF0>-&gt;last_swap_cnter[i])/</span><span class=cFB>wall</span><span class=cF0>-&gt;last_calc_idle_delta_time</span><span class=cF7>)</span><span class=cF0>);
<a name="l86"></a> </span><span class=cF7>}</span><span class=cF0>
<a name="l87"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,0,l--,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>WHITE</span><span class=cF0>,
<a name="l88"></a> </span><span class=cF6>&quot; ___Description____ #__Task__ UnusedStk_ _UsedMem__/_AllocMem_ &quot;</span><span class=cF0>
<a name="l89"></a> </span><span class=cF6>&quot;______Flags_____&quot;</span><span class=cF0>);
<a name="l90"></a>
<a name="l91"></a> </span><span class=cF1>if</span><span class=cF0> (!</span><span class=cF7>(</span><span class=cFB>winmgr</span><span class=cF0>.updates&amp;31</span><span class=cF7>)</span><span class=cF0> || !*</span><span class=cFB>wall</span><span class=cF0>-&gt;top_line) </span><span class=cF7>{</span><span class=cF0>
<a name="l92"></a> </span><span class=cF5>Date2Struct</span><span class=cF0>(&amp;ds,</span><span class=cF5>Now</span><span class=cF0>+</span><span class=cFB>local_time_offset</span><span class=cF0>);
<a name="l93"></a> i=</span><span class=cFB>sys_code_bp</span><span class=cF0>-&gt;alloced_u8s-</span><span class=cFB>sys_code_bp</span><span class=cF0>-&gt;used_u8s;
<a name="l94"></a> </span><span class=cF1>if</span><span class=cF0> (</span><span class=cFB>sys_data_bp</span><span class=cF0>)
<a name="l95"></a> i+=</span><span class=cFB>sys_data_bp</span><span class=cF0>-&gt;alloced_u8s-</span><span class=cFB>sys_data_bp</span><span class=cF0>-&gt;used_u8s;
<a name="l96"></a> </span><span class=cF5>StrPrint</span><span class=cF0>(</span><span class=cFB>wall</span><span class=cF0>-&gt;top_line,
<a name="l97"></a> </span><span class=cF6>&quot;%3tZ %02d/%02d %02d:%02d:%02d FPS:%2tf Mem:%010X CPU&quot;</span><span class=cF0>,
<a name="l98"></a> ds.day_of_week,</span><span class=cF6>&quot;ST_DAYS_OF_WEEK&quot;</span><span class=cF0>,ds.mon,ds.day_of_mon,
<a name="l99"></a> ds.hour,ds.min,ds.sec,</span><span class=cFB>winmgr</span><span class=cF0>.fps,i);
<a name="l100"></a> </span><span class=cF7>}</span><span class=cF0>
<a name="l101"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,0,0,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>WHITE</span><span class=cF0>,</span><span class=cFB>wall</span><span class=cF0>-&gt;top_line);
<a name="l102"></a>
<a name="l103"></a> </span><span class=cF1>if</span><span class=cF0> (</span><span class=cFB>scrncast</span><span class=cF0>.record)
<a name="l104"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,44-4,0,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>RED</span><span class=cF0>,</span><span class=cF6>&quot;*&quot;</span><span class=cF0>);
<a name="l105"></a> </span><span class=cF1>for</span><span class=cF0> (i=0;i&lt;</span><span class=cFB>mp_cnt</span><span class=cF0>;i++) </span><span class=cF7>{</span><span class=cF0>
<a name="l106"></a> c=&amp;</span><span class=cFB>cpu_structs</span><span class=cF0>[i];
<a name="l107"></a> </span><span class=cF1>if</span><span class=cF0> (i&amp;1)
<a name="l108"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,44+i*2,0,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>WHITE</span><span class=cF0>,</span><span class=cF6>&quot;%2tf&quot;</span><span class=cF0>,100.0*</span><span class=cF7>(</span><span class=cF0>1.0-c-&gt;idle_factor</span><span class=cF7>)</span><span class=cF0>);
<a name="l109"></a> </span><span class=cF1>else</span><span class=cF0>
<a name="l110"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,44+i*2,0,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>YELLOW</span><span class=cF0>,</span><span class=cF6>&quot;%2tf&quot;</span><span class=cF0>,100.0*</span><span class=cF7>(</span><span class=cF0>1.0-c-&gt;idle_factor</span><span class=cF7>)</span><span class=cF0>);
<a name="l111"></a> </span><span class=cF7>}</span><span class=cF0>
<a name="l112"></a>
<a name="l113"></a> st=</span><span class=cF5>ScanCode2KeyName</span><span class=cF0>(</span><span class=cFB>kbd</span><span class=cF0>.last_down_scan_code);
<a name="l114"></a> </span><span class=cF5>TextPrint</span><span class=cF0>(</span><span class=cF5>Fs</span><span class=cF0>,80-18,0,</span><span class=cF3>BLUE</span><span class=cF0>&lt;&lt;4+</span><span class=cF3>YELLOW</span><span class=cF0>,</span><span class=cF6>&quot;%18ts&quot;</span><span class=cF0>,st);
<a name="l115"></a> </span><span class=cF5>Free</span><span class=cF0>(st);
<a name="l116"></a>
<a name="l117"></a> </span><span class=cF5>Fs</span><span class=cF0>-&gt;hash_table=old_hash;
<a name="l118"></a> </span><span class=cFB>wall</span><span class=cF0>-&gt;last_calc_idle_cnt=</span><span class=cFB>winmgr</span><span class=cF0>.t-&gt;calc_idle_cnt;
<a name="l119"></a>}
<a name="l120"></a></span><span class=cFA>
<a name="l121"></a>&lt;1&gt;/* Graphics Not Rendered in HTML */</span><span class=cF0>
<a name="l122"></a>
<a name="l123"></a>
<a name="l124"></a>
<a name="l125"></a></span><span class=cF1>U0</span><span class=cF0> </span><span class=cF5>DrawTermBttn</span><span class=cF0>(</span><span class=cF9>CDC</span><span class=cF0> *dc,</span><span class=cF9>CCtrl</span><span class=cF0> *c)
<a name="l126"></a>{
<a name="l127"></a> </span><span class=cF1>if</span><span class=cF0> (</span><span class=cF5>Blink</span><span class=cF0>)
<a name="l128"></a> </span><span class=cF5>Sprite3</span><span class=cF0>(dc,c-&gt;left,c-&gt;top,0,</span><span class=cFA>&lt;1&gt;</span><span class=cF0>);
<a name="l129"></a>}
<a name="l130"></a>
<a name="l131"></a></span><span class=cF1>U0</span><span class=cF0> </span><span class=cF5>LeftClickTermBttn</span><span class=cF0>(</span><span class=cF9>CCtrl</span><span class=cF0> *,</span><span class=cF9>I64</span><span class=cF0>,</span><span class=cF9>I64</span><span class=cF0>,</span><span class=cF1>Bool</span><span class=cF0> down)
<a name="l132"></a>{
<a name="l133"></a> </span><span class=cF1>if</span><span class=cF0> (down)
<a name="l134"></a> </span><span class=cF5>User</span><span class=cF0>;
<a name="l135"></a>}
<a name="l136"></a>
<a name="l137"></a></span><span class=cF9>CCtrl</span><span class=cF0> *</span><span class=cF5>TermBttnNew</span><span class=cF0>()
<a name="l138"></a>{
<a name="l139"></a> </span><span class=cF9>I64</span><span class=cF0> min_x,max_x,min_y,max_y;
<a name="l140"></a> </span><span class=cF9>CCtrl</span><span class=cF0> *c=</span><span class=cF5>ACAlloc</span><span class=cF0>(</span><span class=cF1>sizeof</span><span class=cF7>(</span><span class=cF9>CCtrl</span><span class=cF7>)</span><span class=cF0>);
<a name="l141"></a>
<a name="l142"></a> c-&gt;win_task=</span><span class=cFB>sys_winmgr_task</span><span class=cF0>;
<a name="l143"></a> c-&gt;flags=</span><span class=cF3>CTRLF_SHOW</span><span class=cF0>;
<a name="l144"></a> c-&gt;type=</span><span class=cF3>CTRLT_GENERIC</span><span class=cF0>;
<a name="l145"></a> c-&gt;draw_it=&amp;</span><span class=cF5>DrawTermBttn</span><span class=cF0>;
<a name="l146"></a> c-&gt;left_click=&amp;</span><span class=cF5>LeftClickTermBttn</span><span class=cF0>;
<a name="l147"></a>
<a name="l148"></a> </span><span class=cF5>SpriteExtents</span><span class=cF0>(</span><span class=cFA>&lt;1&gt;</span><span class=cF0>,&amp;min_x,&amp;max_x,&amp;min_y,&amp;max_y);
<a name="l149"></a></span><span class=cF2>//min must be zero</span><span class=cF0>
<a name="l150"></a> c-&gt;left=</span><span class=cFB>sys_winmgr_task</span><span class=cF0>-&gt;pix_width-(max_x-min_x+1);
<a name="l151"></a> c-&gt;right=c-&gt;left+(max_x-min_x+1)-1;
<a name="l152"></a> c-&gt;top=</span><span class=cFB>sys_winmgr_task</span><span class=cF0>-&gt;pix_height-(max_y-min_y+1);
<a name="l153"></a> c-&gt;bottom=c-&gt;top+(max_y-min_y+1)-1;
<a name="l154"></a>
<a name="l155"></a> </span><span class=cF5>QueIns</span><span class=cF0>(c,</span><span class=cFB>sys_winmgr_task</span><span class=cF0>-&gt;last_ctrl);
<a name="l156"></a> </span><span class=cF5>TaskDerivedValsUpdate</span><span class=cF0>(</span><span class=cFB>sys_winmgr_task</span><span class=cF0>);
<a name="l157"></a>
<a name="l158"></a> </span><span class=cF1>return</span><span class=cF0> c;
<a name="l159"></a>}
<a name="l160"></a>
<a name="l161"></a></span><span class=cF1>U0</span><span class=cF0> </span><span class=cF5>WallPaperInit</span><span class=cF0>()
<a name="l162"></a>{
<a name="l163"></a> </span><span class=cF5>TermBttnNew</span><span class=cF0>;
<a name="l164"></a> </span><span class=cFB>gr</span><span class=cF0>.fp_wall_paper=&amp;</span><span class=cF5>WallPaper</span><span class=cF0>;
<a name="l165"></a>}
</span></pre></body>
</html>