|
@@ -199,6 +199,7 @@
|
|
|
return minutes + " min, " + seconds + " sec";
|
|
|
},
|
|
|
hangUp: function () {
|
|
|
+ var sef = this;
|
|
|
if (this.otSession) {
|
|
|
try {
|
|
|
this.otSession.disconnect();
|
|
@@ -210,7 +211,9 @@
|
|
|
this.started = false;
|
|
|
this.startTime = false;
|
|
|
this.videoActive = false;
|
|
|
- window.location.reload();
|
|
|
+ if(self.publisher){
|
|
|
+ self.publisher.destroy();
|
|
|
+ }
|
|
|
// this.client = false;
|
|
|
}
|
|
|
},
|
|
@@ -371,7 +374,7 @@
|
|
|
height: '100%',
|
|
|
};
|
|
|
var publisher = OT.initPublisher('self-view', publisherOptions, self.handleOpenTokError);
|
|
|
-
|
|
|
+ self.publisher = publisher;
|
|
|
publisher.on('streamCreated', function (event) {
|
|
|
var selfView = $('#self-view');
|
|
|
selfView.attr('data-stream', event.stream.id);
|