From f31746e76c064c5fa930d5b3ad5dbc0a565c355d Mon Sep 17 00:00:00 2001 From: Awais Date: Wed, 13 May 2015 13:44:55 +0500 Subject: [PATCH] ECOM-1471 Hiding the text. --- lms/static/js/verify_student/views/webcam_photo_view.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lms/static/js/verify_student/views/webcam_photo_view.js b/lms/static/js/verify_student/views/webcam_photo_view.js index 20fc55468e..6e60b180bc 100644 --- a/lms/static/js/verify_student/views/webcam_photo_view.js +++ b/lms/static/js/verify_student/views/webcam_photo_view.js @@ -82,6 +82,7 @@ this.stream = stream; video.src = this.URL.createObjectURL( stream ); video.play(); + this.trigger('webcam-loaded'); }, getVideo: function() { @@ -220,6 +221,7 @@ _.extend( this.backend, Backbone.Events ); this.listenTo( this.backend, 'error', this.handleError ); + this.listenTo( this.backend, 'webcam-loaded', this.handleWebcamLoaded ); }, isSupported: function() { @@ -285,6 +287,11 @@ } }, + handleWebcamLoaded: function( errorTitle, errorMsg ) { + // Hide the text behind camera + $( "#camera .placeholder-art", this.el ).hide(); + }, + handleError: function( errorTitle, errorMsg ) { // Hide the buttons $( "#webcam_capture_button", this.el ).addClass('is-hidden');