🔨 添加 vnc 配置.

This commit is contained in:
lijiahangmax
2025-07-07 00:03:45 +08:00
parent e72a9d97cd
commit 4b25de3811
7 changed files with 240 additions and 1 deletions

View File

@@ -24,9 +24,11 @@ package org.dromara.visor.module.terminal.convert;
import org.dromara.visor.common.session.config.RdpConnectConfig;
import org.dromara.visor.common.session.config.SshConnectConfig;
import org.dromara.visor.common.session.config.VncConnectConfig;
import org.dromara.visor.module.terminal.handler.terminal.model.config.TerminalSessionRdpConfig;
import org.dromara.visor.module.terminal.handler.terminal.model.config.TerminalSessionSftpConfig;
import org.dromara.visor.module.terminal.handler.terminal.model.config.TerminalSessionSshConfig;
import org.dromara.visor.module.terminal.handler.terminal.model.config.TerminalSessionVncConfig;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;
@@ -48,4 +50,6 @@ public interface TerminalSessionConvert {
TerminalSessionRdpConfig toRdp(RdpConnectConfig domain);
TerminalSessionVncConfig toVnc(VncConnectConfig domain);
}

View File

@@ -138,4 +138,24 @@ public class TerminalChannelExtra {
// -------------------- vnc --------------------
/**
* 交换红蓝
*/
private Boolean swapRedBlue;
/**
* 光标
*/
private String cursor;
/**
* 压缩等级
*/
private Integer compressLevel;
/**
* 质量等级
*/
private Integer qualityLevel;
}

View File

@@ -0,0 +1,62 @@
/*
* Copyright (c) 2023 - present Dromara, All rights reserved.
*
* https://visor.dromara.org
* https://visor.dromara.org.cn
* https://visor.orionsec.cn
*
* Members:
* Jiahang Li - ljh1553488six@139.com - author
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.dromara.visor.module.terminal.handler.terminal.model.config;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.SuperBuilder;
import org.dromara.visor.common.session.config.VncConnectConfig;
/**
* 终端会话配置 VNC
*
* @author Jiahang Li
* @version 1.0.0
* @since 2025/6/24 17:08
*/
@Data
@SuperBuilder
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
public class TerminalSessionVncConfig extends VncConnectConfig implements ITerminalSessionConfig {
@Schema(description = "logId")
private Long logId;
@Schema(description = "录屏文件路径")
private String recordPath;
@Schema(description = "")
private Integer width;
@Schema(description = "")
private Integer height;
@Schema(description = "dpi")
private Integer dpi;
}