Created
November 5, 2015 06:40
-
-
Save ynonp/f017b0d667319a0aeb16 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
self.load=function(){ | |
var value = localStorage.getItem('picture'); | |
if ( !value ) { return; } | |
self.clear(); | |
var img = new Image; | |
img.src = value; | |
img.onload = function(){ | |
ctx.drawImage(img,0,0); | |
}; | |
}; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment