support for recorder (#361)
This commit is contained in:
		@@ -16,6 +16,9 @@ namespace pxsim {
 | 
			
		||||
        neopixelState: NeoPixelState;
 | 
			
		||||
        fileSystem: FileSystemState;
 | 
			
		||||
 | 
			
		||||
        // visual
 | 
			
		||||
        view: SVGElement;
 | 
			
		||||
 | 
			
		||||
        constructor() {
 | 
			
		||||
            super()
 | 
			
		||||
 | 
			
		||||
@@ -123,10 +126,14 @@ namespace pxsim {
 | 
			
		||||
            }), opts);
 | 
			
		||||
 | 
			
		||||
            document.body.innerHTML = ""; // clear children
 | 
			
		||||
            document.body.appendChild(viewHost.getView());
 | 
			
		||||
            document.body.appendChild(this.view = viewHost.getView());
 | 
			
		||||
 | 
			
		||||
            return Promise.resolve();
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        screenshot(): string {
 | 
			
		||||
            return svg.toDataUri(new XMLSerializer().serializeToString(this.view));
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    export function initRuntimeWithDalBoard() {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user