From fd045043a1fdf476689a719c8b7ac756e5119bd4 Mon Sep 17 00:00:00 2001 From: fufesou <13586388+fufesou@users.noreply.github.com> Date: Wed, 29 May 2024 19:10:15 +0800 Subject: [PATCH 1/3] fix: flutter image pub, version 3 to 4, get bytes (#8202) Signed-off-by: fufesou --- flutter/lib/models/model.dart | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/flutter/lib/models/model.dart b/flutter/lib/models/model.dart index 9f43f0c7b5..54ba4e595c 100644 --- a/flutter/lib/models/model.dart +++ b/flutter/lib/models/model.dart @@ -1699,13 +1699,15 @@ const _forbiddenCursorPng = const _defaultCursorPng = 'iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAFmSURBVFiF7dWxSlxREMbx34QFDRowYBchZSxSCWlMCOwD5FGEFHap06UI7KPsAyyEEIQFqxRaCqYTsqCJFsKkuAeRXb17wrqV918dztw55zszc2fo6Oh47MR/e3zO1/iAHWmznHKGQwx9ip/LEbCfazbsoY8j/JLOhcC6sCW9wsjEwJf483AC9nPNc1+lFRwI13d+l3rYFS799rFGxJMqARv2pBXh+72XQ7gWvklPS7TmMl9Ak/M+DqrENvxAv/guKKApuKPWl0/TROK4+LbSqzhuB+OZ3fRSeFPWY+Fkyn56Y29hfgTSpnQ+s98cvorVey66uPlNFxKwZOYLCGfCs5n9NMYVrsp6mvXSoFqpqYFDvMBkStgJJe93dZOwVXxbqUnBENulydSReqUrDhcX0PT2EXarBYS3GNXMhboinBgIl9K71kg0L3+PvyYGdVpruT2MwrF0iotiXfIwus0Dj+OOjo6Of+e7ab74RkpgAAAAAElFTkSuQmCC'; +const kPreForbiddenCursorId = -2; final preForbiddenCursor = PredefinedCursor( png: _forbiddenCursorPng, - id: -2, + id: kPreForbiddenCursorId, ); +const kPreDefaultCursorId = -1; final preDefaultCursor = PredefinedCursor( png: _defaultCursorPng, - id: -1, + id: kPreDefaultCursorId, hotxGetter: (double w) => w / 2, hotyGetter: (double h) => h / 2, ); @@ -1730,6 +1732,11 @@ class PredefinedCursor { init() { _image2 = img2.decodePng(base64Decode(png)); if (_image2 != null) { + // The png type of forbidden cursor image is `PngColorType.indexed`. + if (isWindows && id == kPreForbiddenCursorId) { + _image2 = _image2!.convert(format: img2.Format.uint8, numChannels: 4); + } + () async { final defaultImg = _image2!; // This function is called only one time, no need to care about the performance. From 48e8a25f6e8c19357d7d02791966b12134cf2037 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=A6Ltorio?= <165936401+aeltorio@users.noreply.github.com> Date: Wed, 29 May 2024 13:10:47 +0200 Subject: [PATCH 2/3] Add missing french language tips (#8201) * french language tips * makes spaces conformed to original file --------- Co-authored-by: Ronan --- src/lang/fr.rs | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/src/lang/fr.rs b/src/lang/fr.rs index b38b6d4430..931f6ccbf3 100644 --- a/src/lang/fr.rs +++ b/src/lang/fr.rs @@ -578,17 +578,17 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> = ("swap-left-right-mouse", "Intervertir le bouton gauche et droit de la souris"), ("2FA code", "code 2FA"), ("More", "Plus"), - ("enable-2fa-title", ""), - ("enable-2fa-desc", ""), - ("wrong-2fa-code", ""), - ("enter-2fa-title", ""), + ("enable-2fa-title", "Activer l'authentification à double facteur"), + ("enable-2fa-desc", "Veuillez configurer votre authentificateur maintenant. Vous pouvez utiliser une application d’authentification telle qu’Authy, Microsoft ou Google Authenticator sur votre téléphone ou votre ordinateur de bureau.nnScannez le code QR avec votre application et entrez le code affiché par votre application pour activer l’authentification à deux facteurs."), + ("wrong-2fa-code", "Impossible de vérifier le code. Vérifiez que le code et les paramètres d’heure locale sont corrects"), + ("enter-2fa-title", "Authentification à deux facteurs"), ("Email verification code must be 6 characters.", "Le code de vérification email doit comporter 6 caractères"), ("2FA code must be 6 digits.", "le code 2FA doit comporter 6 chiffres"), ("Multiple Windows sessions found", "Plusieurs sessions Windows trouvées"), ("Please select the session you want to connect to", "Merci de sélectionner la session Windows à laquelle vous voulez vous connecter"), ("powered_by_me", ""), - ("outgoing_only_desk_tip", ""), - ("preset_password_warning", ""), + ("outgoing_only_desk_tip", "Il s’agit d’une édition personnalisée.\nVous pouvez vous connecter à d’autres appareils, mais les autres appareils ne peuvent pas se connecter à votre appareil."), + ("preset_password_warning", "Cette édition personnalisée est livrée avec un mot de passe prédéfini. Toute personne connaissant ce mot de passe pourrait prendre le contrôle total de votre appareil. Si vous ne vous y attendiez pas, désinstallez immédiatement le logiciel."), ("Security Alert", "Alerte de sécurité"), ("My address book", "Mon carnet d'adresse"), ("Personal", "Personnel"), @@ -598,22 +598,22 @@ pub static ref T: std::collections::HashMap<&'static str, &'static str> = ("Read-only", "Lecture-seule"), ("Read/Write", "Lecture/Écriture"), ("Full Control", "Control Total"), - ("share_warning_tip", ""), + ("share_warning_tip", "Les champs ci-dessus sont partagés et visibles par les autres."), ("Everyone", "Tout le monde"), - ("ab_web_console_tip", ""), - ("allow-only-conn-window-open-tip", ""), - ("no_need_privacy_mode_no_physical_displays_tip", ""), - ("Follow remote cursor", ""), + ("ab_web_console_tip", "Plus sur la console Web"), + ("allow-only-conn-window-open-tip", "N’autoriser la connexion que si la fenêtre RustDesk est ouverte"), + ("no_need_privacy_mode_no_physical_displays_tip", "Pas d’affichage physique, pas besoin d’utiliser le mode confidentialité."), + ("Follow remote cursor", "Suivre le curseur distant"), ("Follow remote window focus", ""), - ("default_proxy_tip", ""), - ("no_audio_input_device_tip", ""), + ("default_proxy_tip", "Le protocole et le port par défaut sont Socks5 et 1080"), + ("no_audio_input_device_tip", "Aucun périphérique d’entrée audio trouvé."), ("Incoming", "Entrant"), ("Outgoing", "Sortant"), ("Clear Wayland screen selection", ""), ("clear_Wayland_screen_selection_tip", ""), ("confirm_clear_Wayland_screen_selection_tip", ""), - ("android_new_voice_call_tip", ""), - ("texture_render_tip", ""), + ("android_new_voice_call_tip", "Une nouvelle demande d’appel vocal a été reçue. Si vous acceptez, l’audio passera à la communication vocale."), + ("texture_render_tip", "Utilisez le rendu des textures pour rendre les images plus fluides."), ("Use texture rendering", "Utiliser le rendu de texture"), ].iter().cloned().collect(); } From 74c24caae90d23fa1ab8b5b089f036cb5b917955 Mon Sep 17 00:00:00 2001 From: 21pages Date: Wed, 29 May 2024 20:38:56 +0800 Subject: [PATCH 3/3] not show paste menu when mobile control mobile (#8204) Signed-off-by: 21pages --- flutter/lib/common/widgets/toolbar.dart | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/flutter/lib/common/widgets/toolbar.dart b/flutter/lib/common/widgets/toolbar.dart index 7e0d32ab7c..78e8e7a837 100644 --- a/flutter/lib/common/widgets/toolbar.dart +++ b/flutter/lib/common/widgets/toolbar.dart @@ -115,7 +115,10 @@ List toolbarControls(BuildContext context, String id, FFI ffi) { ); } // paste - if (isMobile && perms['keyboard'] != false && perms['clipboard'] != false) { + if (isMobile && + pi.platform != kPeerPlatformAndroid && + perms['keyboard'] != false && + perms['clipboard'] != false) { v.add(TTextMenu( child: Text(translate('Paste')), onPressed: () async {