aboutsummaryrefslogtreecommitdiffstats
path: root/www/js
diff options
context:
space:
mode:
authorStruan Donald <struan@exo.org.uk>2013-06-11 13:04:04 +0100
committerStruan Donald <struan@exo.org.uk>2013-06-11 13:04:04 +0100
commit2e5fe2fd4bb4dc66a1d04a12fe996113f04b9264 (patch)
tree046e2615129693f2a5f30c92215f987c1e41432b /www/js
parent73c9ac7e62ba29639c2f15039764b314b69d194f (diff)
cancel event propogation for photo buttons
Diffstat (limited to 'www/js')
-rw-r--r--www/js/views/photo.js9
1 files changed, 6 insertions, 3 deletions
diff --git a/www/js/views/photo.js b/www/js/views/photo.js
index 8077749..74f3933 100644
--- a/www/js/views/photo.js
+++ b/www/js/views/photo.js
@@ -27,12 +27,14 @@
}
},
- takePhoto: function() {
+ takePhoto: function(e) {
+ e.preventDefault();
var that = this;
navigator.camera.getPicture( function(imgURI) { that.addPhotoSuccess(imgURI); }, function(error) { that.addPhotoFail(error); }, { saveToPhotoAlbum: true, quality: 49, destinationType: Camera.DestinationType.FILE_URI, sourceType: navigator.camera.PictureSourceType.CAMERA, correctOrientation: true });
},
- addPhoto: function() {
+ addPhoto: function(e) {
+ e.preventDefault();
var that = this;
navigator.camera.getPicture( function(imgURI) { that.addPhotoSuccess(imgURI); }, function(error) { that.addPhotoFail(error); }, { saveToPhotoAlbum: false, quality: 49, destinationType: Camera.DestinationType.FILE_URI, sourceType: navigator.camera.PictureSourceType.PHOTOLIBRARY, correctOrientation: true });
},
@@ -63,7 +65,8 @@
}
},
- deletePhoto: function() {
+ deletePhoto: function(e) {
+ e.preventDefault();
var that = this;
var del = FMS.files.deleteURI( this.model.get('file') );