[ui] add a compact edit button for self-hosted settings
@@ -2674,8 +2674,20 @@ export component MainWindow inherits Window {
|
||||
}
|
||||
SettingsToggleRow { label: UiStrings.force-relay; checked <=> root.force-relay-enabled; enabled: !root.settings-session-active; }
|
||||
SettingsToggleRow {
|
||||
label: UiStrings.self-hosted;
|
||||
label-reserve: self-host-edit.width + 84px;
|
||||
checked <=> root.self-hosted-enabled; enabled: !root.settings-session-active; divider: false;
|
||||
SettingsButton { x: 0px; y: 2px; width: parent.width - 60px; height: 32px; quiet: true; align-left: true; text: UiStrings.self-hosted; enabled: !root.settings-session-active; clicked => { root.self-host-settings-open = true; } }
|
||||
self-host-edit := SettingsButton {
|
||||
x: parent.width - self.width - 60px; y: 4px;
|
||||
width: self-host-edit-metrics.preferred-width + 24px; height: 28px;
|
||||
text: GalleryStrings.tr("编辑", "Edit", "Изменить");
|
||||
enabled: !root.settings-session-active;
|
||||
clicked => { root.self-host-settings-open = true; }
|
||||
self-host-edit-metrics := Text {
|
||||
visible: false; accessible-role: none;
|
||||
text: parent.text; font-size: 12px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Text {
|
||||
|
||||
@@ -43,9 +43,9 @@ sudo docker compose ps
|
||||
使用自签证书时,先按 [证书信任步骤](#3-配置信任证书) 在两端导入根证书,再检查连接状态。
|
||||
|
||||
1. 断开现有会话,点击主窗口右上角 **☰ → 设置**。
|
||||
2. 在设置列表中向下滚动,点击 **自托管配置**。
|
||||
2. 在设置列表中向下滚动,点击 **自托管配置** 一行的 **编辑** 按钮。
|
||||
3. 填写 **服务器地址**、**信令服务端口**,点击“确认”。地址支持主机名或 IP(如 `my-server.example.com`),也支持带路径的信令地址(如 `my-server.example.com/signal-path`)或 `https://` / `wss://` URL。URL 内明确填写的端口优先;否则使用单独填写的信令服务端口。所有连接均使用 WSS,带路径的地址需要反向代理将该路径转发到信令 WebSocket 服务,普通网页地址不能直接用于信令连接。
|
||||
4. 回到设置窗口,勾选 **自托管配置** 右侧复选框,再点击“确认”保存。
|
||||
4. 回到设置窗口,打开 **自托管配置** 右侧开关,再点击“保存”。
|
||||
5. 在控制端和被控端执行相同配置。等待两端都显示“已连接服务器”,再使用被控端当前显示的 ID 发起连接。
|
||||
|
||||
地址与端口在最后确认设置时一起保存;格式无效或保存失败时会保留输入并显示错误。
|
||||
|
||||
@@ -43,9 +43,9 @@ sudo docker compose ps
|
||||
For a self-signed deployment, complete the [certificate trust steps](#3-trust-the-tls-certificate) on both clients before checking their connection status.
|
||||
|
||||
1. Disconnect existing sessions and open **☰ → Settings**.
|
||||
2. Scroll down and click **Self-Hosted Config**.
|
||||
2. Scroll down and click **Edit** in the **Self-Hosted Config** row.
|
||||
3. Enter **Server Address** and **Signal Service Port**, then confirm. The address accepts a hostname or IP (such as `my-server.example.com`), a signaling path (such as `my-server.example.com/signal-path`), or an `https://` / `wss://` URL. An explicit URL port takes precedence; otherwise the separate signaling port is used. Connections always use WSS. Paths must be routed to the signaling WebSocket service by your reverse proxy; an ordinary web page is not a signaling endpoint.
|
||||
4. Enable the checkbox beside **Self-Hosted Config**, then click **OK** in the parent settings window.
|
||||
4. Enable the switch beside **Self-Hosted Config**, then click **Save** in the parent settings window.
|
||||
5. Configure both the controller and host this way. Once both report a server connection, connect using the host's currently displayed ID.
|
||||
|
||||
<p align="center">
|
||||
|
||||
@@ -152,7 +152,7 @@ sudo apt install "./crossdesk-virtual-desktop-xfce-linux-amd64-<version>.deb"
|
||||
| 强制中继连接 | 关闭时自动选择连接方式,允许 P2P 和 TURN 中继回退;开启时仅通过中继连接 |
|
||||
| 保存远程画面预览 | 默认开启,保存远程画面预览;关闭后缩略图区域显示被控端平台,并清除已有预览,保留连接记录和密码 |
|
||||
| 被连接时开启隐私屏 | 设置本机被远程连接时是否自动启用隐私屏;会话中可从控制端工具栏切换 |
|
||||
| 自托管配置 | 填写服务器地址和信令服务端口,并勾选启用 |
|
||||
| 自托管配置 | 点击“编辑”填写服务器地址和信令服务端口,使用右侧开关启用 |
|
||||
| 开机自启 / 启用守护进程 | 调整启动与进程守护行为,按界面提示重启后生效 |
|
||||
| 文件保存路径 | 选择接收文件的目录 |
|
||||
|
||||
|
||||
@@ -152,7 +152,7 @@ Open **☰ → Settings** in the top-right corner, choose **General / DeskHub**,
|
||||
| Force Relay | When off, automatically select a connection path with P2P and TURN relay fallback; when on, use relay connections only |
|
||||
| Save remote screen previews | On by default. When disabled, the thumbnail area shows the remote device’s platform and existing previews are cleared; connection records and passwords are preserved |
|
||||
| Privacy screen on connect | Automatically enable privacy when this computer is controlled remotely; the controller can toggle it from the session toolbar |
|
||||
| Self-Hosted Config | Set the server address and signaling port, then enable the checkbox |
|
||||
| Self-Hosted Config | Click Edit to set the server address and signaling port, then enable the switch on the right |
|
||||
| Auto Start / Enable Daemon | Configure startup and process supervision; restart as indicated by the UI |
|
||||
| File Save Path | Choose where received files are saved |
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
## 来源 / Sources
|
||||
|
||||
- **2026-10-25** 删除“启用中继服务”开关后,从当前工作区组件重新生成 `desktop-settings-*` 和 `desktop-settings-network-*` 共 4 张中英文截图,展示可独立操作的“强制中继连接”。
|
||||
- **2026-10-25** 删除“启用中继服务”开关,并将自托管配置拆分为普通标签、“编辑”按钮和开关后,从当前工作区组件重新生成常规设置与网络设置共 4 张中英文截图。
|
||||
- **2026-10-25** 从 `ae6f81e8` 的实际 Slint 组件重新生成 16 张中英文截图:更新主窗口、常规设置、桌面墙设置、自托管及关于共 10 张,新增 IP 直连主界面、记住密码弹窗和网络设置共 6 张。使用 Slint 1.17.1、macOS arm64 和 2× 软件渲染。
|
||||
- 捕获程序在**工程外临时目录**中复用现有 [`slint_ui_smoke_test`](../../apps/desktop/tests/slint_ui_smoke_test.cpp) 的截图辅助函数,并注入演示界面状态;没有启动应用运行时、打开监听端口或建立远控会话。没有修改产品组件或工程内测试,临时源码、可执行程序与 PPM 均位于工程外。
|
||||
- 主窗口展示 ID / IP 模式切换、桌面墙入口和各自的近期设备;IP 模式展示地址编辑、六位密码和默认端口 52888,网络设置展示“启用 IP 直连”及关闭说明。IP 近期设备的 `LAN` 标记表示记录类型,不代表在线探测结果。
|
||||
@@ -14,7 +14,7 @@
|
||||
- 缩略图沿用既有公开页面截图:`fixtures/source.png` 来自 [CrossDesk Xmake 源码页](https://github.com/kunkundi/crossdesk/blob/ios-support/xmake.lua),`fixtures/website.png` 来自 [CrossDesk 官网](https://www.crossdesk.cn/),两者采集于 2026-09-07。它们只用于展示预览效果,不代表这些页面正在对应设备上运行,页面中的版本信息也不代表最新发布。
|
||||
- `web-client.png` 保留 **2026-09-25** 从 [Web 客户端](https://web.crossdesk.cn/) 采集的 1280 × 720 连接首页,页面版本为 `2026.09.24.2`,ID 与密码为空。本次未重新采集 Web 页面;桌面设备预览继续复用这张图片。
|
||||
|
||||
On **2026-10-25**, 16 images were rendered from the actual Slint components at `ae6f81e8`: ten refreshed images (main window, General settings, DeskHub settings, self-hosting, and About) and six additions (Direct IP mode, its password dialog, and Network settings), in Chinese and English. Later that day, the four General and Network settings images were refreshed from the working tree after removing Enable TURN Service, showing the independent Force Relay switch. The capture-only program reused the existing helper functions in an external temporary directory, using Slint 1.17.1 on macOS arm64 at 2× scale. Capture did not modify product components or repository tests, and no listeners or remote sessions were opened. IDs, IPs, passwords, device records, connection states, and update results are illustrative; `LAN` labels indicate record type, not an online check. The checked Remember password box is a demonstration choice. The other six desktop screenshots remain from 2026-10-19, public-page fixtures from 2026-09-07, and the Web image from 2026-09-25. Native mobile screenshots are not included.
|
||||
On **2026-10-25**, 16 images were rendered from the actual Slint components at `ae6f81e8`: ten refreshed images (main window, General settings, DeskHub settings, self-hosting, and About) and six additions (Direct IP mode, its password dialog, and Network settings), in Chinese and English. Later that day, the four General and Network settings images were refreshed from the working tree after removing Enable TURN Service and separating Self-Hosted Config into a label, Edit button, and switch. The capture-only program reused the existing helper functions in an external temporary directory, using Slint 1.17.1 on macOS arm64 at 2× scale. Capture did not modify product components or repository tests, and no listeners or remote sessions were opened. IDs, IPs, passwords, device records, connection states, and update results are illustrative; `LAN` labels indicate record type, not an online check. The checked Remember password box is a demonstration choice. The other six desktop screenshots remain from 2026-10-19, public-page fixtures from 2026-09-07, and the Web image from 2026-09-25. Native mobile screenshots are not included.
|
||||
|
||||
## 文件 / Files
|
||||
|
||||
|
||||
|
Before Width: | Height: | Size: 146 KiB After Width: | Height: | Size: 148 KiB |
|
Before Width: | Height: | Size: 150 KiB After Width: | Height: | Size: 152 KiB |
|
Before Width: | Height: | Size: 158 KiB After Width: | Height: | Size: 160 KiB |
|
Before Width: | Height: | Size: 146 KiB After Width: | Height: | Size: 148 KiB |