blog.csdn.net/qq_42899245…

// 视频窗口分割
CommandMenu:{
width: '100%',
height: '100%',
num: 1, // 视频个数
}
methods: {
// videoSize() {
// console.log(20);
// this.videoOpen = true;
// },
/
handleCommand(command) {
// x = 列数 y行数
const xy = command == '1'?{x:1,y:1}:command == '4'?{x:2,y:2}:command == '6'?{x:3,y:2}:command == '8'?{x:2,y:4}:command == '16'?{x:4,y:4}:command == '36'?{x:6,y:6}:command == '64'?{x:8,y:8}:{x:1,y:1};
const width = 100 / xy.x;
const height = 100 / xy.y;
this.$set(this,'CommandMenu',{
width: width+'%',
height: height+'%',
num: Math.round(command),
})
},