1
0
Fork 0
mirror of https://github.com/DanielnetoDotCom/YouPHPTube synced 2025-10-03 01:39:24 +02:00
Oinktube/plugin/PlayerSkins/epgButton.js
2022-08-10 14:09:36 -03:00

20 lines
No EOL
762 B
JavaScript

var Button = videojs.getComponent('Button');
var EPGButton = videojs.extend(Button, {
//constructor: function(player, options) {
constructor: function () {
Button.apply(this, arguments);
this.addClass('EPG-button');
this.controlText("EPG");
setTimeout(function(){avideoTooltip(".EPG-button","EPG");},1000);
},
handleClick: function () {
var url = webSiteRootURL+'plugin/PlayerSkins/epg.php';
url = addQueryStringParameter(url, 'videos_id', mediaId);
console.log('epg clicked');
avideoModalIframeFullTransparent(url);
}
});
videojs.registerComponent('EPGButton', EPGButton);
player.getChild('controlBar').addChild('EPGButton', {}, getPlayerButtonIndex('fullscreenToggle') - 1);