MCPcopy
hub / github.com/methodofaction/Method-Draw / loadSvgString

Function loadSvgString

src/js/Import.js:76–88  ·  view source on GitHub ↗
(str, callback)

Source from the content-addressed store, hash-verified

74 }
75
76 function loadSvgString(str, callback) {
77 var success = svgCanvas.setSvgString(str) !== false;
78 callback = callback || $.noop;
79 if(success) {
80 callback(true);
81 editor.saveCanvas();
82 state.set("canvasTitle", svgCanvas.getDocumentTitle());
83 } else {
84 $.alert("Error: Unable to load SVG data", function() {
85 callback(false);
86 });
87 }
88 }
89
90 function openImage(e){
91 $('#menu_bar').removeClass('active')

Callers 1

openImageFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected