diff options
Diffstat (limited to 'client/button.js')
| -rw-r--r-- | client/button.js | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/client/button.js b/client/button.js index d4336d5..f483e8e 100644 --- a/client/button.js +++ b/client/button.js @@ -105,6 +105,11 @@ function animate2() { delay += 400 * photos.length; delay += 2000; + var canvas = document.getElementById('canvas-final'); + var dataUrl = canvas.toDataURL(); + $('a.share-save').attr('href', dataUrl); + $('a.share-save').attr('download', new Date().getTime()); + _.delay(function() { $('h2.title').html('Done!<div class="sec">This is your icon!</div>'); $('div.final div.final-dominants').hide(); @@ -112,7 +117,6 @@ function animate2() { $('div.about-link').show(); }, delay + 2000); - } Template.layout.events({ @@ -210,7 +214,7 @@ Template.photos.events({ window.print(); }, 'click button.share-save': function (event) { - window.print(); + }, 'click button.share-print': function (event) { window.print(); |
