Merge pull request #8020 from edx/aamir-khan/ECOM-1471-hidden-text-behind-cam-issue

ECOM-1471 Hiding the text.
This commit is contained in:
Awais Qureshi
2015-05-18 11:40:10 +05:00

View File

@@ -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');