временно отключаю возможность авто-сохранения времени просмотра
This commit is contained in:
@@ -5,6 +5,7 @@ const PlayerCore = function(playerObj, titleObj, videoData) {
|
||||
|
||||
const _this = this;
|
||||
|
||||
/* временно отключаю возможность авто-сохранения времени просмотра
|
||||
// сохранение времени просмотра
|
||||
playerObj.bind('play', function() {
|
||||
_this.timeLast = $.now();
|
||||
@@ -26,7 +27,7 @@ const PlayerCore = function(playerObj, titleObj, videoData) {
|
||||
}); //TODO убрать на продакшене
|
||||
}
|
||||
});
|
||||
|
||||
*/
|
||||
this.getType = function() {
|
||||
return videoData.type;
|
||||
};
|
||||
@@ -130,6 +131,7 @@ function msToTime(ms) {
|
||||
};
|
||||
}
|
||||
|
||||
/*
|
||||
function loadPlayerCookieData(playerCore) {
|
||||
let data = Cookies.getJSON(playerCore.path);
|
||||
|
||||
@@ -172,12 +174,13 @@ function loadPlayerCookieData(playerCore) {
|
||||
$('#modal').modal('show');
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
function initPlayer(video_data) {
|
||||
const playerCore = new PlayerCore($('#player'), $('#title'), video_data);
|
||||
|
||||
// загрузка ранее сохранённых данных
|
||||
loadPlayerCookieData(playerCore);
|
||||
//loadPlayerCookieData(playerCore);
|
||||
|
||||
if (playerCore.getType() == 'one_film') {
|
||||
playerCore.setTitle();
|
||||
|
||||
Reference in New Issue
Block a user