An open-source remote desktop application designed for self-hosting, as an alternative to TeamViewer.
Rust androidanydeskdartflatpakflutterflutter-appsioslinuxmacosp2prdpremote-controlremote-desktoprustrust-langteamviewervncwaylandwindows
feat: allow customizing incoming-only quit button text (#16968)
21pages0bfe22083df9
diff --git a/flutter/lib/consts.dart b/flutter/lib/consts.dartindex 90f5e3eb1..ed14e3474 100644--- a/flutter/lib/consts.dart+++ b/flutter/lib/consts.dart@@ -205,6 +205,7 @@ const String kOptionHideServerSetting = "hide-server-settings";const String kOptionHideProxySetting = "hide-proxy-settings";const String kOptionHideWebSocketSetting = "hide-websocket-settings";const String kOptionHideStopService = "hide-stop-service";+const String kOptionQuitButtonText = "quit-button-text";const String kOptionHideRemotePrinterSetting = "hide-remote-printer-settings";const String kOptionHideGeneralSetting = "hide-general-settings";const String kOptionHideSecuritySetting = "hide-security-settings";diff --git a/flutter/lib/desktop/pages/desktop_home_page.dart b/flutter/lib/desktop/pages/desktop_home_page.dartindex 12951ca4e..b9e6c98f2 100644--- a/flutter/lib/desktop/pages/desktop_home_page.dart+++ b/flutter/lib/desktop/pages/desktop_home_page.dart@@ -558,6 +558,8 @@ class _DesktopHomePageState extends State<DesktopHomePage>}}if (bind.isIncomingOnly()) {+ final quitButtonText =+ bind.mainGetBuildinOption(key: kOptionQuitButtonText).trim();return Align(alignment: Alignment.centerRight,child: OutlinedButton(@@ -568,7 +570,7 @@ class _DesktopHomePageState extends State<DesktopHomePage>exit(0);}},- child: Text(translate('Quit')),+ child: Text(quitButtonText.isEmpty ? translate('Quit') : quitButtonText),),).marginAll(14);}diff --git a/libs/base/src/config/keys.rs b/libs/base/src/config/keys.rsindex 5f5bf8f4f..6f7991114 100644--- a/libs/base/src/config/keys.rs+++ b/libs/base/src/config/keys.rs@@ -123,6 +123,7 @@ pub const OPTION_HIDE_PROXY_SETTINGS: &str = "hide-proxy-settings";pub const OPTION_HIDE_REMOTE_PRINTER_SETTINGS: &str = "hide-remote-printer-settings";pub const OPTION_HIDE_WEBSOCKET_SETTINGS: &str = "hide-websocket-settings";pub const OPTION_HIDE_STOP_SERVICE: &str = "hide-stop-service";+pub const OPTION_QUIT_BUTTON_TEXT: &str = "quit-button-text";pub const OPTION_ALLOW_COMMAND_LINE_SETTINGS_WHEN_SETTINGS_DISABLED: &str ="allow-command-line-settings-when-settings-disabled";@@ -373,6 +374,7 @@ pub const KEYS_BUILDIN_SETTINGS: &[&str] = &[OPTION_ENABLE_PERM_CHANGE_IN_ACCEPT_WINDOW,OPTION_HIDE_ELEVATE_BUTTON_IN_ACCEPT_WINDOW,OPTION_ALLOW_COMMAND_LINE_SETTINGS_WHEN_SETTINGS_DISABLED,+ OPTION_QUIT_BUTTON_TEXT,];#[cfg(test)]