special_video添加信号源时只能添加视频和图片

This commit is contained in:
fangxiang 2022-08-03 20:02:25 +08:00
parent cbbb812212
commit 262b95ebdc
3 changed files with 39 additions and 29 deletions

View File

@ -3,9 +3,12 @@ export interface IScreenInfo {
screen_height: number; screen_height: number;
unit_width: number; unit_width: number;
unit_height: number; unit_height: number;
wall_rows: number; screen_rows: number;
wall_cols: number; screen_cols: number;
desktop_col: number; desktop_col: number;
desktop_row: number;
desktop_width: number;
desktop_height: number;
} }
export class SpecialVideoHelper { export class SpecialVideoHelper {
@ -22,15 +25,17 @@ export class SpecialVideoHelper {
const unit_height = SpecialVideoHelper.kScreenHeight / desktp_row; const unit_height = SpecialVideoHelper.kScreenHeight / desktp_row;
const screen_width = wall_cols * unit_width; const screen_width = wall_cols * unit_width;
const screen_height = wall_rows * unit_height; const screen_height = wall_rows * unit_height;
console.log(screen_width);
return { return {
screen_width, screen_width,
screen_height, screen_height,
unit_width, unit_width,
unit_height, unit_height,
wall_rows, screen_rows: wall_rows,
wall_cols, screen_cols: wall_cols,
desktop_col, desktop_col,
desktop_row: desktop_col,
desktop_width: SpecialVideoHelper.kScreenWidth,
desktop_height: SpecialVideoHelper.kScreenHeight,
}; };
} }
} }

View File

@ -392,10 +392,6 @@ export default defineComponent({
label: $t.t("multimedia file"), label: $t.t("multimedia file"),
value: "EwindowType::Multimedia", value: "EwindowType::Multimedia",
}, },
{
label: $t.t("Web"),
value: "EwindowType::Web",
},
{ {
label: $t.t("image"), label: $t.t("image"),
value: "EwindowType::Image", value: "EwindowType::Image",
@ -404,6 +400,10 @@ export default defineComponent({
label: $t.t("rtsp"), label: $t.t("rtsp"),
value: "EwindowType::Rtsp", value: "EwindowType::Rtsp",
}, },
{
label: $t.t("Web"),
value: "EwindowType::Web",
},
{ {
label: $t.t("clock"), label: $t.t("clock"),
value: "EwindowType::Clock", value: "EwindowType::Clock",
@ -417,11 +417,13 @@ export default defineComponent({
const refresh_signal_source_options = () => { const refresh_signal_source_options = () => {
signal_source_options.value = []; signal_source_options.value = [];
if ($store.state.isLedPlayer()) {
for (const item of build_signal_source_options) { for (const item of build_signal_source_options) {
signal_source_options.value.push(item); signal_source_options.value.push(item);
} }
if ( if (
($store.state.device_attribute & Protocol.EDeviceAttribute.CustomISV) == ($store.state.device_attribute &
Protocol.EDeviceAttribute.CustomISV) ==
0 0
) { ) {
signal_source_options.value.push({ signal_source_options.value.push({
@ -436,6 +438,10 @@ export default defineComponent({
signal_source_options.value.splice(index, 1); signal_source_options.value.splice(index, 1);
} }
} }
} else if ($store.state.isSpecialVideo()) {
signal_source_options.value = [];
signal_source_options.value = build_signal_source_options.slice(0, 2);
}
}; };
refresh_signal_source_options(); refresh_signal_source_options();

View File

@ -352,9 +352,8 @@ export default defineComponent({
}; };
if ( if (
window_rect.x + window_rect.width > window_rect.x + window_rect.width > screen_width.value ||
$store.state.device_screen_width || window_rect.y + window_rect.height > screen_height.value
window_rect.y + window_rect.height > $store.state.device_screen_height
) { ) {
$q.dialog({ $q.dialog({
title: $t.t("Warning"), title: $t.t("Warning"),