diff --git a/js/views/attachment_view.js b/js/views/attachment_view.js index 0d52908293..1a577d2b3d 100644 --- a/js/views/attachment_view.js +++ b/js/views/attachment_view.js @@ -7,11 +7,15 @@ var ImageView = Backbone.View.extend({ tagName: 'img', events: { - 'load': 'update' + 'load': 'update', + 'click': 'open' }, update: function() { this.$el.trigger('update'); }, + open: function () { + window.open(this.$el.attr('src'), '_blank'); + }, render: function(dataUrl) { this.$el.attr('src', dataUrl); return this;