mirror of
https://github.com/weyne85/rustdesk.git
synced 2025-10-29 17:00:05 +00:00
Check if peer info is set
Signed-off-by: fufesou <shuanglongchen@yeah.net>
This commit is contained in:
@@ -228,18 +228,12 @@ class _RemotePageState extends State<RemotePage>
|
||||
removeSharedStates(widget.id);
|
||||
}
|
||||
|
||||
Widget emptyOverlay() => GestureDetector(
|
||||
behavior: HitTestBehavior.translucent,
|
||||
onTap: () {
|
||||
bind.sessionInputOsPassword(sessionId: sessionId, value: '');
|
||||
},
|
||||
child: BlockableOverlay(
|
||||
/// the Overlay key will be set with _blockableOverlayState in BlockableOverlay
|
||||
/// see override build() in [BlockableOverlay]
|
||||
state: _blockableOverlayState,
|
||||
underlying: Container(
|
||||
color: Colors.transparent,
|
||||
),
|
||||
Widget emptyOverlay() => BlockableOverlay(
|
||||
/// the Overlay key will be set with _blockableOverlayState in BlockableOverlay
|
||||
/// see override build() in [BlockableOverlay]
|
||||
state: _blockableOverlayState,
|
||||
underlying: Container(
|
||||
color: Colors.transparent,
|
||||
),
|
||||
);
|
||||
|
||||
@@ -273,7 +267,8 @@ class _RemotePageState extends State<RemotePage>
|
||||
inputModel: _ffi.inputModel,
|
||||
child: getBodyForDesktop(context))),
|
||||
Obx(
|
||||
() => _ffi.ffiModel.waitForFirstImage.isTrue
|
||||
() => _ffi.ffiModel.pi.isSet.isTrue &&
|
||||
_ffi.ffiModel.waitForFirstImage.isTrue
|
||||
? emptyOverlay()
|
||||
: Offstage(),
|
||||
),
|
||||
@@ -286,6 +281,9 @@ class _RemotePageState extends State<RemotePage>
|
||||
onEnterOrLeaveImageCleaner: () =>
|
||||
_onEnterOrLeaveImage4Toolbar = null,
|
||||
),
|
||||
Obx(
|
||||
() => _ffi.ffiModel.pi.isSet.isFalse ? emptyOverlay() : Offstage(),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
@@ -20,6 +20,7 @@ import 'package:get/get.dart';
|
||||
import 'package:bot_toast/bot_toast.dart';
|
||||
|
||||
import '../../common/widgets/dialog.dart';
|
||||
import '../../models/model.dart';
|
||||
import '../../models/platform_model.dart';
|
||||
|
||||
class _MenuTheme {
|
||||
@@ -266,7 +267,11 @@ class _ConnectionTabPageState extends State<ConnectionTabPage> {
|
||||
if (e.kind != ui.PointerDeviceKind.mouse) {
|
||||
return;
|
||||
}
|
||||
if (e.buttons == 2) {
|
||||
final remotePage = tabController.state.value.tabs
|
||||
.firstWhere((tab) => tab.key == key)
|
||||
.page as RemotePage;
|
||||
if (remotePage.ffi.ffiModel.pi.isSet.isTrue &&
|
||||
e.buttons == 2) {
|
||||
showRightMenu(
|
||||
(CancelFunc cancelFunc) {
|
||||
return _tabMenuBuilder(key, cancelFunc);
|
||||
|
||||
Reference in New Issue
Block a user