mirror of
https://github.com/rustdesk/rustdesk.git
synced 2026-04-05 04:41:30 +03:00
feat, multi_flutter_ui_sessions
Signed-off-by: dignow <linlong1265@gmail.com>
This commit is contained in:
@@ -1054,7 +1054,7 @@ Widget msgboxIcon(String type) {
|
||||
if (type == 'on-uac' || type == 'on-foreground-elevated') {
|
||||
iconData = Icons.admin_panel_settings;
|
||||
}
|
||||
if (type == "info") {
|
||||
if (type.contains('info')) {
|
||||
iconData = Icons.info;
|
||||
}
|
||||
if (iconData != null) {
|
||||
@@ -2317,7 +2317,7 @@ Widget dialogButton(String text,
|
||||
}
|
||||
}
|
||||
|
||||
int version_cmp(String v1, String v2) {
|
||||
int versionCmp(String v1, String v2) {
|
||||
return bind.versionToNumber(v: v1) - bind.versionToNumber(v: v2);
|
||||
}
|
||||
|
||||
@@ -2589,3 +2589,25 @@ String getDesktopTabLabel(String peerId, String alias) {
|
||||
}
|
||||
return label;
|
||||
}
|
||||
|
||||
String getChooseDisplayBehavior() {
|
||||
var current = bind.mainGetOptionSync(key: kKeyChooseDisplayBehavior);
|
||||
if (![kChooseDisplayBehaviorSwitch, kChooseDisplayBehaviorOpen]
|
||||
.contains(current)) {
|
||||
current = kChooseDisplayBehaviorOpen;
|
||||
}
|
||||
return current;
|
||||
}
|
||||
|
||||
sessionRefreshVideo(SessionID sessionId, PeerInfo pi) async {
|
||||
if (pi.currentDisplay == kAllDisplayValue) {
|
||||
for (int i = 0; i < pi.displays.length; i++) {
|
||||
await bind.sessionRefresh(sessionId: sessionId, display: i);
|
||||
}
|
||||
} else {
|
||||
await bind.sessionRefresh(sessionId: sessionId, display: pi.currentDisplay);
|
||||
}
|
||||
}
|
||||
|
||||
bool get isChooseDisplayToOpen =>
|
||||
getChooseDisplayBehavior() != kChooseDisplayBehaviorSwitch;
|
||||
|
||||
Reference in New Issue
Block a user