feat(sender): 首页移除投屏画面,请求投屏直开独立窗口,新增文件传输
- 删除首页 VideoView:画面只在独立原生窗口显示,首页改为状态卡片(分辨率/帧数/错误) - 新增 MirrorBar 卡片,请求投屏/停止投屏从控制工具栏独立出来;点请求即打开独立窗口再下发 msg_type=8 - 停止投屏同时下发 stop 并关闭窗口;控制工具栏移除投屏按钮 - 独立窗口无画面时居中提示「等待被控端画面…」 - 新增 core/file_client.dart 与 file_browser_page:浏览/下载到 Downloads/TTSTD/上传,带进度与错误提示 - AppSettings 增加 filePort/fileToken 并接入设置页与首页文件卡片
This commit is contained in:
1 parent
993097df00
commit
d3ff293877
10 files changed
+1029
-189
No files matched your search
@@ -121,6 +121,10 @@ class AppSettings {
|
||||
final bool clipboardSync;
|
||||
final bool fileTransfer;
|
||||
final int bitrateMbps;
|
||||
/// 被控端文件服务端口(LocalSend 风格 HTTP,默认 53317)。
|
||||
final int filePort;
|
||||
/// 被控端文件服务访问令牌,被控端主界面会显示。
|
||||
final String fileToken;
|
||||
|
||||
const AppSettings({
|
||||
this.signalingUrl = '',
|
||||
@@ -132,6 +136,8 @@ class AppSettings {
|
||||
this.clipboardSync = true,
|
||||
this.fileTransfer = true,
|
||||
this.bitrateMbps = 8,
|
||||
this.filePort = 53317,
|
||||
this.fileToken = '',
|
||||
});
|
||||
|
||||
static const defaults = AppSettings();
|
||||
@@ -148,6 +154,8 @@ class AppSettings {
|
||||
bool? clipboardSync,
|
||||
bool? fileTransfer,
|
||||
int? bitrateMbps,
|
||||
int? filePort,
|
||||
String? fileToken,
|
||||
}) {
|
||||
return AppSettings(
|
||||
signalingUrl: signalingUrl ?? this.signalingUrl,
|
||||
@@ -159,6 +167,8 @@ class AppSettings {
|
||||
clipboardSync: clipboardSync ?? this.clipboardSync,
|
||||
fileTransfer: fileTransfer ?? this.fileTransfer,
|
||||
bitrateMbps: bitrateMbps ?? this.bitrateMbps,
|
||||
filePort: filePort ?? this.filePort,
|
||||
fileToken: fileToken ?? this.fileToken,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -175,6 +185,8 @@ class AppSettings {
|
||||
clipboardSync: json['clipboardSync'] as bool? ?? defaults.clipboardSync,
|
||||
fileTransfer: json['fileTransfer'] as bool? ?? defaults.fileTransfer,
|
||||
bitrateMbps: (json['bitrateMbps'] is num ? json['bitrateMbps'] as num : 8).toInt(),
|
||||
filePort: (json['filePort'] is num ? json['filePort'] as num : 53317).toInt(),
|
||||
fileToken: (json['fileToken'] ?? defaults.fileToken).toString(),
|
||||
);
|
||||
}
|
||||
|
||||
@@ -188,5 +200,7 @@ class AppSettings {
|
||||
'clipboardSync': clipboardSync,
|
||||
'fileTransfer': fileTransfer,
|
||||
'bitrateMbps': bitrateMbps,
|
||||
'filePort': filePort,
|
||||
'fileToken': fileToken,
|
||||
};
|
||||
}
|
||||
Reference in new issue
Block a user