2015-07-11 12:30:55 +00:00
|
|
|
var blessed = require('../');
|
|
|
|
var fs = require('fs');
|
|
|
|
|
|
|
|
var screen = blessed.screen({
|
|
|
|
tput: true,
|
|
|
|
smartCSR: true,
|
2015-07-22 02:23:57 +00:00
|
|
|
dump: __dirname + '/logs/video.log',
|
|
|
|
warnings: true
|
2015-07-11 12:30:55 +00:00
|
|
|
});
|
|
|
|
|
|
|
|
var video = blessed.video({
|
|
|
|
parent: screen,
|
|
|
|
left: 1,
|
|
|
|
top: 1,
|
|
|
|
width: '90%',
|
|
|
|
height: '90%',
|
|
|
|
border: 'line',
|
|
|
|
file: process.argv[2]
|
|
|
|
});
|
|
|
|
|
|
|
|
video.focus();
|
|
|
|
|
|
|
|
screen.render();
|
|
|
|
|
|
|
|
screen.key(['q', 'C-q', 'C-c'], function() {
|
|
|
|
process.exit(0);
|
|
|
|
});
|