diff --git a/lms/static/js/verify_student/CameraCapture.as b/lms/static/js/verify_student/CameraCapture.as index a3f68863c6..1d55f80b37 100644 --- a/lms/static/js/verify_student/CameraCapture.as +++ b/lms/static/js/verify_student/CameraCapture.as @@ -58,6 +58,7 @@ package ExternalInterface.addCallback("reset", reset); ExternalInterface.addCallback("imageDataUrl", imageDataUrl); ExternalInterface.addCallback("cameraAuthorized", cameraAuthorized); + ExternalInterface.addCallback("hasCamera", hasCamera); // Notify the container that the SWF is ready to be called. ExternalInterface.call("setSWFIsReady"); @@ -108,6 +109,10 @@ package return permissionGiven; } + public function hasCamera():Boolean { + return (Camera.names.length != 0); + } + public function statusHandler(event:StatusEvent):void { switch (event.code) { diff --git a/lms/static/js/verify_student/CameraCapture.swf b/lms/static/js/verify_student/CameraCapture.swf index 47f87c9493..5ad17e7631 100644 Binary files a/lms/static/js/verify_student/CameraCapture.swf and b/lms/static/js/verify_student/CameraCapture.swf differ diff --git a/lms/static/js/verify_student/photocapture.js b/lms/static/js/verify_student/photocapture.js index 32164f1728..490bb8a840 100644 --- a/lms/static/js/verify_student/photocapture.js +++ b/lms/static/js/verify_student/photocapture.js @@ -189,9 +189,11 @@ function initSnapshotHandler(names, hasHtml5CameraSupport) { } function objectTagForFlashCamera(name) { + // I manually update this to have ?v={2,3,4, etc} to avoid caching of flash + // objects on local dev. return '';