You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
89 lines
4.1 KiB
89 lines
4.1 KiB
{
|
|
id: 'db_node_%%%NODEID%%%',
|
|
layout:'vbox',
|
|
tools: [{
|
|
id:'gear',
|
|
handler: function(){
|
|
}
|
|
}],
|
|
frame: true,
|
|
draggable: false,
|
|
collapsible: false,
|
|
bodyStyle: 'padding: 0px;',
|
|
title: '%%%NODENAME%%%',
|
|
sukaMineWidth: -1,
|
|
/*
|
|
{
|
|
id: 'db_node_%%%NODEID%%%_pic',
|
|
border: true,
|
|
width: '100%',
|
|
//html: '<div id="img-%%%NODEID%%%" style="display: flex;align-items: center;" ><img id="img-img-%%%NODEID%%%" ondblclick="fullScreen(\'img-%%%NODEID%%%\');" style="cursor: zoom-in" src="%%%SELURL%%%" width="100%" /><div style="float: left; position: absolute; left: 30px; bottom: 50px; z-index: 1000;"><table width="100%" border=0><tr><td width="24"><img id="img_btn_010_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/player/010.png"></td><td width="24"><img id="img_btn_032_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/player/032.png"></td><td width="24"><img id="img_btn_033_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/player/033.png"></td><td width="24"><img id="img_btn_034_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/player/034.png"></td><td> </td></tr><tr><td><img id="img_btn_011_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/player/011.png"></td><td><img id="img_btn_031_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/player/031.png"></td><td><img id="img_btn_020_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/basic/020.png"></td><td><img id="img_btn_027_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/player/027.png"></td><td> </td></tr><tr><td>%%%HBTN%%%</td><td><img id="img_btn_030_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/player/030.png"></td><td><img id="img_btn_029_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/player/029.png"></td><td><img id="img_btn_028_%%%NODEID%%%" class="ptz_ctrl_btn" src="/style/png/player/028.png"></td><td> </td></tr></table></div></div>'
|
|
//html: '<div id="img-%%%NODEID%%%" style="display: flex;align-items: center;" ><img id="img-img-%%%NODEID%%%" ondblclick="fullScreen(\'img-%%%NODEID%%%\');" style="cursor: zoom-in" src="/style/assets/no-signal.png" width="100%" /></div>'
|
|
//html: '<video id="video-%%%NODEID%%%" class="video-js" controls preload="auto" width="640" height="264" data-setup="{}"><source src="/lib/controller/data/videos/e4e18614af6059501d88ca39e76db15b.mp4" type="video/mp4"></video>'
|
|
html:''
|
|
},
|
|
|
|
*/
|
|
items:[{
|
|
id: 'db_node_%%%NODEID%%%_pic',
|
|
border: true,
|
|
width: '100%',
|
|
html: '<video id="video-%%%NODEID%%%" class="video-js" controls preload="auto" poster="/style/assets/no-signal.png" width="100%" data-setup="{}"></video>'
|
|
}/*{
|
|
xtype: 'button',
|
|
id: 'db_download_video',
|
|
scale: 'large',
|
|
enableToggle: true,
|
|
disabled: true,
|
|
text: 'Download Video File',
|
|
width: '100%',
|
|
handler: function(){
|
|
if( DownloadVideoLink!= '' ){
|
|
var link = document.createElement("a");
|
|
// If you don't know the name or want to use
|
|
// the webserver default set name = ''
|
|
//link.setAttribute('download', name );
|
|
link.setAttribute('download', '' );
|
|
link.href = DownloadVideoLink;
|
|
document.body.appendChild(link);
|
|
link.click();
|
|
link.remove();
|
|
}
|
|
}
|
|
}*/],
|
|
listeners:{
|
|
resize: function( p, adjWidth, adjHeight, rawWidth, rawHeight ){
|
|
if( rawWidth!= undefined ){
|
|
if( p.sukaMineWidth != adjWidth ){
|
|
p.sukaMineWidth = adjWidth;
|
|
var XX = p.sukaMineWidth * %%%HEIGHT%%% / %%%WIDTH%%%;
|
|
p.setHeight( XX + 32 );
|
|
//var z = Ext.getCmp('db_download_video');
|
|
var z = document.getElementById( 'video-%%%NODEID%%%' );
|
|
z.height = XX;
|
|
};
|
|
};
|
|
},
|
|
afterrender: function( p ){
|
|
var xx = p.getWidth() * %%%HEIGHT%%% / %%%WIDTH%%%;
|
|
p.setHeight( xx + 32 );
|
|
VideoLinks[%%%NODEID%%%] = '';
|
|
$('#video-%%%NODEID%%%').on('timeupdate', function(){
|
|
if( cEventETS > 0 ){
|
|
if( this.currentTime > cEventETS ) {
|
|
cEventETS = 0;
|
|
this.pause();
|
|
};
|
|
};//console.log('the time was updated to: ' + this.currentTime);
|
|
});
|
|
var player = videojs( 'video-%%%NODEID%%%' );
|
|
player.fluid(true);
|
|
|
|
//player.fill(true);
|
|
},
|
|
beforedestroy: function(){
|
|
var oldPlayer = document.getElementById( 'video-%%%NODEID%%%' );
|
|
videojs( oldPlayer ).dispose();
|
|
}
|
|
}
|
|
}
|