aboutsummaryrefslogtreecommitdiffstats
path: root/www/js
diff options
context:
space:
mode:
authorStruan Donald <struan@exo.org.uk>2012-12-24 10:09:17 +0000
committerStruan Donald <struan@exo.org.uk>2012-12-24 10:09:17 +0000
commit2a6b25490db6e718fe98a6521916b33c705a9707 (patch)
treec24a2bb04de2cd3fe226a2019347e949583cee8d /www/js
parent55f8730beb5bfd4ac5515f9c99b5c716aeae8886 (diff)
do not complain if photo taking/selecting canceled by user
Diffstat (limited to 'www/js')
-rw-r--r--www/js/mobile.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/www/js/mobile.js b/www/js/mobile.js
index 37c8763..e399dc4 100644
--- a/www/js/mobile.js
+++ b/www/js/mobile.js
@@ -450,8 +450,13 @@ function delPhoto() {
}
function takePhotoFail(message) {
- alert('There was a problem taking your photo');
- console.log('error taking picture: ' + message);
+ if ( message != 'no image selected' &&
+ message != 'Selection cancelled.' &&
+ message != 'Camera cancelled.'
+ ) {
+ navigator.notification.alert('There was a problem taking your photo', null, 'Photo');
+ console.log('error taking picture: ' + message);
+ }
}
function takePhoto(type) {