mirror of
https://github.com/rustdesk/rustdesk.git
synced 2025-12-16 21:16:35 +00:00
Merge remote-tracking branch 'upstream/master' into file-manager-redesign
This commit is contained in:
@@ -43,11 +43,8 @@ class _AddressBookState extends State<AddressBook> {
|
||||
return Obx(() {
|
||||
if (gFFI.userModel.userName.value.isEmpty) {
|
||||
return Center(
|
||||
child: ElevatedButton(
|
||||
onPressed: loginDialog,
|
||||
child: Text(translate("Login"))
|
||||
)
|
||||
);
|
||||
child: ElevatedButton(
|
||||
onPressed: loginDialog, child: Text(translate("Login"))));
|
||||
} else {
|
||||
if (gFFI.abModel.abLoading.value) {
|
||||
return const Center(
|
||||
@@ -153,13 +150,13 @@ class _AddressBookState extends State<AddressBook> {
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Text(translate('Tags')),
|
||||
GestureDetector(
|
||||
onTapDown: (e) {
|
||||
final x = e.globalPosition.dx;
|
||||
final y = e.globalPosition.dy;
|
||||
Listener(
|
||||
onPointerDown: (e) {
|
||||
final x = e.position.dx;
|
||||
final y = e.position.dy;
|
||||
menuPos = RelativeRect.fromLTRB(x, y, x, y);
|
||||
},
|
||||
onTap: () => _showMenu(menuPos),
|
||||
onPointerUp: (_) => _showMenu(menuPos),
|
||||
child: ActionMore()),
|
||||
],
|
||||
);
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_hbb/models/state_model.dart';
|
||||
|
||||
import '../../common.dart';
|
||||
import '../../models/input_model.dart';
|
||||
|
||||
class RawKeyFocusScope extends StatelessWidget {
|
||||
@@ -20,13 +18,6 @@ class RawKeyFocusScope extends StatelessWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final FocusOnKeyCallback? onKey;
|
||||
if (isAndroid) {
|
||||
onKey = inputModel.handleRawKeyEvent;
|
||||
} else {
|
||||
onKey = stateGlobal.grabKeyboard ? inputModel.handleRawKeyEvent : null;
|
||||
}
|
||||
|
||||
return FocusScope(
|
||||
autofocus: true,
|
||||
child: Focus(
|
||||
@@ -34,7 +25,7 @@ class RawKeyFocusScope extends StatelessWidget {
|
||||
canRequestFocus: true,
|
||||
focusNode: focusNode,
|
||||
onFocusChange: onFocusChange,
|
||||
onKey: onKey,
|
||||
onKey: inputModel.handleRawKeyEvent,
|
||||
child: child));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user