Add peer option: zoom cursor & show menubar on conn

Signed-off-by: fufesou <shuanglongchen@yeah.net>
This commit is contained in:
fufesou
2022-11-16 18:07:58 +08:00
parent 46423614c8
commit 9a70725090
28 changed files with 121 additions and 23 deletions

View File

@@ -47,7 +47,8 @@ class MenubarState {
}
_initSet(bool s, bool p) {
show = RxBool(s);
// Show remubar when connection is established.
show = RxBool(true);
_pin = RxBool(p);
}
@@ -1109,6 +1110,25 @@ class _RemoteMenubarState extends State<RemoteMenubar> {
);
}());
/// Show remote cursor
displayMenu.add(() {
final opt = 'zoom-cursor';
final state = PeerBoolOption.find(widget.id, opt);
return MenuEntrySwitch2<String>(
switchType: SwitchType.scheckbox,
text: translate('Zoom cursor'),
getter: () {
return state;
},
setter: (bool v) async {
state.value = v;
await bind.sessionToggleOption(id: widget.id, value: opt);
},
padding: padding,
dismissOnClicked: true,
);
}());
/// Show quality monitor
displayMenu.add(MenuEntrySwitch<String>(
switchType: SwitchType.scheckbox,