Open dodgepudding opened 11 years ago
after release the instance using function "remove()" then rebuild imgAreaSelect, the selection area DIV will disappear. the code like this:
editorhandle = $('#cropimg').imgAreaSelect({ handles: true, instance: true, show: true, imageHeight: 400, imageWidth: 400, x1:0,y1:0,x2:200,y2:200 }); //you can see selection area showed. //then release and rebuild immediately editorhandle.remove(); editorhandle = $('#cropimg').imgAreaSelect({ handles: true, instance: true, show: true, imageHeight: 400, imageWidth: 400, x1:0,y1:0,x2:200,y2:200 }); //selection area DIVs disappeared, but you can even crop the image.
after release the instance using function "remove()" then rebuild imgAreaSelect, the selection area DIV will disappear. the code like this:
editorhandle = $('#cropimg').imgAreaSelect({ handles: true, instance: true, show: true, imageHeight: 400, imageWidth: 400, x1:0,y1:0,x2:200,y2:200 }); //you can see selection area showed. //then release and rebuild immediately editorhandle.remove(); editorhandle = $('#cropimg').imgAreaSelect({ handles: true, instance: true, show: true, imageHeight: 400, imageWidth: 400, x1:0,y1:0,x2:200,y2:200 }); //selection area DIVs disappeared, but you can even crop the image.