添加按SHIFT和ALT自由开窗的功能

This commit is contained in:
fangxiang 2022-03-11 16:46:46 +08:00
parent 9e70ed2a51
commit 8a82e41555
5 changed files with 21 additions and 9 deletions

View File

@ -83,6 +83,7 @@ export default class RemoteDataExangeProcesser {
this.plan_notify(void 0); this.plan_notify(void 0);
this.plan_notify = null; this.plan_notify = null;
} }
this.plan_notify = $q.notify({ this.plan_notify = $q.notify({
position: "center", position: "center",
color: "positive", color: "positive",

View File

@ -8,13 +8,23 @@
<template v-slot:default-header="prop"> <template v-slot:default-header="prop">
<q-item <q-item
class="full-width" class="full-width"
:disable="$store.state.current_running_plan.trim() != ''"
clickable clickable
@dblclick=" @dblclick="
(evt) => (evt) => {
$store.state.current_running_plan.trim() == '' && if (
!prop.node.is_group && $store.state.current_running_plan.trim() == '' &&
callMode(prop.node.item_data) !prop.node.is_group
) {
callMode(prop.node.item_data);
} else {
$q.notify({
type: 'warning',
message: $t('plan running! can\'t call mode!'),
position: 'top',
timeout: 1500,
});
}
}
" "
> >
<q-item-section avatar> <q-item-section avatar>

View File

@ -242,9 +242,8 @@ export default defineComponent({
$t.t("update file upload") + $t.t("update file upload") +
$t.t("success") + $t.t("success") +
"! \n" + "! \n" +
$t.t( upgrade_type.value +
"the system automatically restarts after the upgrade is complete" $t.t("automatically restarts after the upgrade is complete"),
),
position: "top", position: "top",
timeout: 1500, timeout: 1500,
}); });

View File

@ -395,4 +395,6 @@ export default {
"clean screen": "清屏", "clean screen": "清屏",
"CN/EN switch": "中英文切换", "CN/EN switch": "中英文切换",
DD: "天", DD: "天",
"automatically restarts after the upgrade is complete": "升级完成后自动重启",
"plan running! can't call mode!": "预案正在运行!不能调用模式!",
}; };

View File

@ -273,7 +273,7 @@ export default defineComponent({
if (plan_running.value) { if (plan_running.value) {
return; return;
} }
if (evt.ctrlKey && wall.value) { if ((evt.ctrlKey || evt.shiftKey || evt.altKey) && wall.value) {
let left = let left =
wall.value.offsetLeft + (wall.value.parentElement?.offsetLeft ?? 0); wall.value.offsetLeft + (wall.value.parentElement?.offsetLeft ?? 0);
let top = let top =