diff options
Diffstat (limited to 'html/085scenario_console.cc.html')
-rw-r--r-- | html/085scenario_console.cc.html | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/html/085scenario_console.cc.html b/html/085scenario_console.cc.html index 9a5586b3..9a3487f8 100644 --- a/html/085scenario_console.cc.html +++ b/html/085scenario_console.cc.html @@ -128,7 +128,7 @@ if ('onhashchange' in window) { <span id="L66" class="LineNr"> 66 </span> <span class="Normal">for</span> <span class="Delimiter">(</span><span class="Normal">int</span> i = <span class="Constant">0</span><span class="Delimiter">;</span> i < <a href='001help.cc.html#L141'>SIZE</a><span class="Delimiter">(</span>r<span class="Delimiter">.</span>steps<span class="Delimiter">);</span> ++i<span class="Delimiter">)</span> <span class="Delimiter">{</span> <span id="L67" class="LineNr"> 67 </span> <span class="Conceal">¦</span> <span class="Normal">const</span> instruction& inst = r<span class="Delimiter">.</span>steps<span class="Delimiter">.</span>at<span class="Delimiter">(</span>i<span class="Delimiter">);</span> <span id="L68" class="LineNr"> 68 </span> <span class="Conceal">¦</span> <span class="Normal">if</span> <span class="Delimiter">(</span>inst<span class="Delimiter">.</span>name == <span class="Constant">"left-click"</span><span class="Delimiter">)</span> <span class="Delimiter">{</span> -<span id="L69" class="LineNr"> 69 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing 'left-click' event starting at "</span> << Current_routine<span class="Delimiter">-></span>alloc << <a href='003trace.cc.html#L185'>end</a><span class="Delimiter">();</span> +<span id="L69" class="LineNr"> 69 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing 'left-click' event starting at "</span> << Current_routine<span class="Delimiter">-></span>alloc << <a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> <span id="L70" class="LineNr"> 70 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='001help.cc.html#L221'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> curr_address<span class="Delimiter">,</span> <span class="Comment">/*</span><span class="Comment">tag for 'touch-event' variant of 'event' exclusive-container</span><span class="Comment">*/</span><span class="Constant">2</span><span class="Delimiter">);</span> <span id="L71" class="LineNr"> 71 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='001help.cc.html#L221'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> curr_address+<span class="Comment">/*</span><span class="Comment">skip tag</span><span class="Comment">*/</span><span class="Constant">1</span>+<span class="Comment">/*</span><span class="Comment">offset of 'type' in 'mouse-event'</span><span class="Comment">*/</span><span class="Constant">0</span><span class="Delimiter">,</span> TB_KEY_MOUSE_LEFT<span class="Delimiter">);</span> <span id="L72" class="LineNr"> 72 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='001help.cc.html#L221'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> curr_address+<span class="Comment">/*</span><span class="Comment">skip tag</span><span class="Comment">*/</span><span class="Constant">1</span>+<span class="Comment">/*</span><span class="Comment">offset of 'row' in 'mouse-event'</span><span class="Comment">*/</span><span class="Constant">1</span><span class="Delimiter">,</span> <a href='002test.cc.html#L92'>to_integer</a><span class="Delimiter">(</span>inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>name<span class="Delimiter">));</span> @@ -136,7 +136,7 @@ if ('onhashchange' in window) { <span id="L74" class="LineNr"> 74 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> curr_address += <a href='085scenario_console.cc.html#L296'>size_of_event</a><span class="Delimiter">();</span> <span id="L75" class="LineNr"> 75 </span> <span class="Conceal">¦</span> <span class="Delimiter">}</span> <span id="L76" class="LineNr"> 76 </span> <span class="Conceal">¦</span> <span class="Normal">else</span> <span class="Normal">if</span> <span class="Delimiter">(</span>inst<span class="Delimiter">.</span>name == <span class="Constant">"press"</span><span class="Delimiter">)</span> <span class="Delimiter">{</span> -<span id="L77" class="LineNr"> 77 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing 'press' event starting at "</span> << curr_address << <a href='003trace.cc.html#L185'>end</a><span class="Delimiter">();</span> +<span id="L77" class="LineNr"> 77 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing 'press' event starting at "</span> << curr_address << <a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> <span id="L78" class="LineNr"> 78 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> string key = inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>name<span class="Delimiter">;</span> <span id="L79" class="LineNr"> 79 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Normal">if</span> <span class="Delimiter">(</span><a href='002test.cc.html#L86'>is_integer</a><span class="Delimiter">(</span>key<span class="Delimiter">))</span> <span id="L80" class="LineNr"> 80 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='001help.cc.html#L221'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> curr_address+<span class="Constant">1</span><span class="Delimiter">,</span> <a href='002test.cc.html#L92'>to_integer</a><span class="Delimiter">(</span>key<span class="Delimiter">));</span> @@ -157,18 +157,18 @@ if ('onhashchange' in window) { <span id="L95" class="LineNr"> 95 </span> <span class="Conceal">¦</span> <span class="Normal">else</span> <span class="Delimiter">{</span> <span id="L96" class="LineNr"> 96 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Comment">// keyboard input</span> <span id="L97" class="LineNr"> 97 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> assert<span class="Delimiter">(</span>inst<span class="Delimiter">.</span>name == <span class="Constant">"type"</span><span class="Delimiter">);</span> -<span id="L98" class="LineNr"> 98 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing 'type' event starting at "</span> << curr_address << <a href='003trace.cc.html#L185'>end</a><span class="Delimiter">();</span> +<span id="L98" class="LineNr"> 98 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing 'type' event starting at "</span> << curr_address << <a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> <span id="L99" class="LineNr"> 99 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Normal">const</span> string& contents = inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>name<span class="Delimiter">;</span> <span id="L100" class="LineNr">100 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Normal">const</span> <span class="Normal">char</span>* raw_contents = contents<span class="Delimiter">.</span>c_str<span class="Delimiter">();</span> <span id="L101" class="LineNr">101 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Normal">int</span> num_keyboard_events = <a href='038new_text.cc.html#L131'>unicode_length</a><span class="Delimiter">(</span>contents<span class="Delimiter">);</span> <span id="L102" class="LineNr">102 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Normal">int</span> curr = <span class="Constant">0</span><span class="Delimiter">;</span> <span id="L103" class="LineNr">103 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Normal">for</span> <span class="Delimiter">(</span><span class="Normal">int</span> i = <span class="Constant">0</span><span class="Delimiter">;</span> i < num_keyboard_events<span class="Delimiter">;</span> ++i<span class="Delimiter">)</span> <span class="Delimiter">{</span> -<span id="L104" class="LineNr">104 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing 'text' tag at "</span> << curr_address << <a href='003trace.cc.html#L185'>end</a><span class="Delimiter">();</span> +<span id="L104" class="LineNr">104 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing 'text' tag at "</span> << curr_address << <a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> <span id="L105" class="LineNr">105 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='001help.cc.html#L221'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> curr_address<span class="Delimiter">,</span> <span class="Comment">/*</span><span class="Comment">tag for 'text' variant of 'event' exclusive-container</span><span class="Comment">*/</span><span class="Constant">0</span><span class="Delimiter">);</span> <span id="L106" class="LineNr">106 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Normal">uint32_t</span> curr_character<span class="Delimiter">;</span> <span id="L107" class="LineNr">107 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> assert<span class="Delimiter">(</span>curr < <a href='001help.cc.html#L141'>SIZE</a><span class="Delimiter">(</span>contents<span class="Delimiter">));</span> <span id="L108" class="LineNr">108 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> tb_utf8_char_to_unicode<span class="Delimiter">(</span>&curr_character<span class="Delimiter">,</span> &raw_contents[curr]<span class="Delimiter">);</span> -<span id="L109" class="LineNr">109 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing character "</span> << curr_character << <span class="Constant">" at "</span> << curr_address+<span class="Comment">/*</span><span class="Comment">skip exclusive container tag</span><span class="Comment">*/</span><span class="Constant">1</span> << <a href='003trace.cc.html#L185'>end</a><span class="Delimiter">();</span> +<span id="L109" class="LineNr">109 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing character "</span> << curr_character << <span class="Constant">" at "</span> << curr_address+<span class="Comment">/*</span><span class="Comment">skip exclusive container tag</span><span class="Comment">*/</span><span class="Constant">1</span> << <a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> <span id="L110" class="LineNr">110 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <a href='001help.cc.html#L221'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> curr_address+<span class="Comment">/*</span><span class="Comment">skip exclusive container tag</span><span class="Comment">*/</span><span class="Constant">1</span><span class="Delimiter">,</span> curr_character<span class="Delimiter">);</span> <span id="L111" class="LineNr">111 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> curr += tb_utf8_char_length<span class="Delimiter">(</span>raw_contents[curr]<span class="Delimiter">);</span> <span id="L112" class="LineNr">112 </span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> <span class="Conceal">¦</span> curr_address += <a href='085scenario_console.cc.html#L296'>size_of_event</a><span class="Delimiter">();</span> @@ -178,9 +178,9 @@ if ('onhashchange' in window) { <span id="L116" class="LineNr">116 </span> assert<span class="Delimiter">(</span>curr_address == event_data_address+size<span class="Delimiter">);</span> <span id="L117" class="LineNr">117 </span> <span class="Comment">// wrap the array of events in a console object</span> <span id="L118" class="LineNr">118 </span> <span class="Normal">int</span> console_address = allocate<span class="Delimiter">(</span><a href='085scenario_console.cc.html#L306'>size_of_console</a><span class="Delimiter">());</span> -<span id="L119" class="LineNr">119 </span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing console in "</span> << console_address << <a href='003trace.cc.html#L185'>end</a><span class="Delimiter">();</span> +<span id="L119" class="LineNr">119 </span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing console in "</span> << console_address << <a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> <span id="L120" class="LineNr">120 </span> <a href='001help.cc.html#L221'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> CONSOLE<span class="Delimiter">,</span> console_address<span class="Delimiter">);</span> -<span id="L121" class="LineNr">121 </span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing console data in "</span> << console_address+<span class="Comment">/*</span><span class="Comment">skip refcount</span><span class="Comment">*/</span><span class="Constant">1</span>+<span class="Comment">/*</span><span class="Comment">offset of 'data' in container 'events'</span><span class="Comment">*/</span><span class="Constant">1</span> << <a href='003trace.cc.html#L185'>end</a><span class="Delimiter">();</span> +<span id="L121" class="LineNr">121 </span> <a href='003trace.cc.html#L161'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing console data in "</span> << console_address+<span class="Comment">/*</span><span class="Comment">skip refcount</span><span class="Comment">*/</span><span class="Constant">1</span>+<span class="Comment">/*</span><span class="Comment">offset of 'data' in container 'events'</span><span class="Comment">*/</span><span class="Constant">1</span> << <a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> <span id="L122" class="LineNr">122 </span> <a href='001help.cc.html#L221'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> console_address+<span class="Comment">/*</span><span class="Comment">skip refcount</span><span class="Comment">*/</span><span class="Constant">1</span>+<span class="Comment">/*</span><span class="Comment">offset of 'data' in container 'events'</span><span class="Comment">*/</span><span class="Constant">1</span><span class="Delimiter">,</span> event_data_address<span class="Delimiter">);</span> <span id="L123" class="LineNr">123 </span> <span class="Comment">// increment refcount for event data</span> <span id="L124" class="LineNr">124 </span> <a href='001help.cc.html#L221'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> event_data_address<span class="Delimiter">,</span> <span class="Constant">1</span><span class="Delimiter">);</span> @@ -327,7 +327,7 @@ if ('onhashchange' in window) { <span id="L265" class="LineNr">265 </span><span class="Normal">case</span> REPLACE_IN_CONSOLE: <span class="Delimiter">{</span> <span id="L266" class="LineNr">266 </span> assert<span class="Delimiter">(</span>scalar<span class="Delimiter">(</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">)));</span> <span id="L267" class="LineNr">267 </span> <span class="Normal">if</span> <span class="Delimiter">(</span>!get_or_insert<span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> CONSOLE<span class="Delimiter">))</span> <span class="Delimiter">{</span> -<span id="L268" class="LineNr">268 </span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L168'>raise</a> << <span class="Constant">"console not initialized</span><span class="cSpecial">\n</span><span class="Constant">"</span> << <a href='003trace.cc.html#L185'>end</a><span class="Delimiter">();</span> +<span id="L268" class="LineNr">268 </span> <span class="Conceal">¦</span> <a href='003trace.cc.html#L168'>raise</a> << <span class="Constant">"console not initialized</span><span class="cSpecial">\n</span><span class="Constant">"</span> << <a href='003trace.cc.html#L197'>end</a><span class="Delimiter">();</span> <span id="L269" class="LineNr">269 </span> <span class="Conceal">¦</span> <span class="Identifier">break</span><span class="Delimiter">;</span> <span id="L270" class="LineNr">270 </span> <span class="Delimiter">}</span> <span id="L271" class="LineNr">271 </span> <span class="Normal">int</span> console_address = <a href='001help.cc.html#L228'>get_or_insert</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> CONSOLE<span class="Delimiter">);</span> |