mirror of
https://github.com/wanghongenpin/proxypin.git
synced 2026-05-16 15:56:51 +08:00
Merge branch 'develop' into flutter-3.19.6
This commit is contained in:
@@ -18,7 +18,7 @@ class UriBuild {
|
||||
|
||||
class UriUtils {
|
||||
//map转url参数
|
||||
static String mapToQuery(Map<String, dynamic>? map) {
|
||||
static String mapToQuery(Map? map) {
|
||||
if (map == null) {
|
||||
return '';
|
||||
}
|
||||
|
||||
@@ -67,7 +67,7 @@ class RequestRewriteState extends State<RequestRewriteWidget> {
|
||||
}
|
||||
|
||||
bool onKeyEvent(KeyEvent event) {
|
||||
if (event.logicalKey == LogicalKeyboardKey.escape && Navigator.canPop(context)) {
|
||||
if (HardwareKeyboard.instance.isLogicalKeyPressed(LogicalKeyboardKey.escape) && Navigator.canPop(context)) {
|
||||
Navigator.maybePop(context);
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -76,6 +76,11 @@ class _ScriptWidgetState extends State<ScriptWidget> {
|
||||
}
|
||||
|
||||
bool onKeyEvent(KeyEvent event) {
|
||||
if (HardwareKeyboard.instance.isLogicalKeyPressed(LogicalKeyboardKey.escape) && Navigator.canPop(context)) {
|
||||
Navigator.maybePop(context);
|
||||
return true;
|
||||
}
|
||||
|
||||
if ((HardwareKeyboard.instance.isMetaPressed || HardwareKeyboard.instance.isControlPressed) &&
|
||||
event.logicalKey == LogicalKeyboardKey.keyW) {
|
||||
HardwareKeyboard.instance.removeHandler(onKeyEvent);
|
||||
|
||||
Reference in New Issue
Block a user