sclass TranspileWithErrorWindow { settable S snippetID; JFastLogView_noWrap transpilationErrorBox; settable Runnable transpileAction; event success; event error(Throwable error); /*void transpile { var tfs = new TranspileForServer_v2(snippetID); tfs.run(); }*/ public void run aka runMe() { infoBox("Transpiling " + snippetID); try { transpileAction.run(); } catch e { infoBox("Transpilation error. " + e); awt { bool first = transpilationErrorBox == null; transpilationErrorBox = maximizeFrame(scrollAllTheWayDown(showText_fast_noWrap(transpilationErrorBox, "Transpilation Error", renderStackTrace(e)))); if (first) { setFrameIcon(#1101268, transpilationErrorBox); addButtonsToWindow(transpilationErrorBox, jbuttonWithDisable("Medium transpile", r runMe) ); } } error(e); ret; } infoBox("Transpiled OK!"); hideWindow(transpilationErrorBox); transpilationErrorBox = null; success(); } /*selfType coresToUse(int coresToUse) { tfs.runTranspiler.coresToUse(coresToUse); this; }*/ }