editor: fix copy deep copy to prevent clipboard mutations

This commit is contained in:
jean-emmanuel 2017-04-07 23:55:54 +02:00
parent 467183bf31
commit a6c3f19dfa

View file

@ -55,7 +55,7 @@ var init = function(){
clickY = Math.round((d.offsetY + d.target.scrollTop) / (GRIDWIDTH * PXSCALE)) * GRIDWIDTH
// actions['<i class="fa fa-edit"></i> Edit'] = function(){editObject(container,data)}
if (type=='widget') actions['<i class="fa fa-copy"></i> Copy'] = function(){CLIPBOARD=data}
if (type=='widget') actions['<i class="fa fa-copy"></i> Copy'] = function(){CLIPBOARD=JSON.parse(JSON.stringify(data))}
if (type=='widget') actions['<i class="fa fa-cut"></i> Cut'] = function(){
CLIPBOARD=JSON.parse(JSON.stringify(data))