!7 cmodule NewSnippetAsSF > DynPrintLogAndEnabled { start { dm_onSnippetCreated(voidfunc(S snippetID) { print("New snippet! " + snippetID); if (getSnippetType(snippetID) == snippetType_JavaXInclude()) { S text = loadSnippet(snippetID); S sfName = first(findFunctionDefinitions(text)); if (sfName != null) showPackedFrameInBottomRightCorner( centerAndSouthWithMargins(jlabel("Add standard function: " + sfName + "?"), jbutton("OK", rThread { addStandardFunctionWithAnimation(snippetID) }) )); } }); } }