wayland tip
This commit is contained in:
parent
3c584a7c01
commit
3f009a3bc7
@ -301,15 +301,6 @@ class _DesktopHomePageState extends State<DesktopHomePage>
|
||||
}
|
||||
|
||||
Widget buildHelpCards() {
|
||||
if (Platform.isWindows) {
|
||||
if (!bind.mainIsInstalled()) {
|
||||
return buildInstallCard(
|
||||
"", "install_tip", "Install", bind.mainGotoInstall);
|
||||
} else if (bind.mainIsInstalledLowerVersion()) {
|
||||
return buildInstallCard("Status", "Your installation is lower version.",
|
||||
"Click to upgrade", bind.mainUpdateMe);
|
||||
}
|
||||
}
|
||||
if (updateUrl.isNotEmpty) {
|
||||
return buildInstallCard(
|
||||
"Status",
|
||||
@ -322,7 +313,15 @@ class _DesktopHomePageState extends State<DesktopHomePage>
|
||||
if (systemError.isNotEmpty) {
|
||||
return buildInstallCard("", systemError, "", () {});
|
||||
}
|
||||
if (Platform.isMacOS) {
|
||||
if (Platform.isWindows) {
|
||||
if (!bind.mainIsInstalled()) {
|
||||
return buildInstallCard(
|
||||
"", "install_tip", "Install", bind.mainGotoInstall);
|
||||
} else if (bind.mainIsInstalledLowerVersion()) {
|
||||
return buildInstallCard("Status", "Your installation is lower version.",
|
||||
"Click to upgrade", bind.mainUpdateMe);
|
||||
}
|
||||
} else if (Platform.isMacOS) {
|
||||
if (!bind.mainIsCanScreenRecording(prompt: false)) {
|
||||
return buildInstallCard("Permissions", "config_screen", "Configure",
|
||||
() async {
|
||||
@ -342,8 +341,19 @@ class _DesktopHomePageState extends State<DesktopHomePage>
|
||||
bind.mainIsInstalledDaemon(prompt: true);
|
||||
});
|
||||
}
|
||||
} else if (Platform.isLinux) {
|
||||
if (bind.mainCurrentIsWayland()) {
|
||||
return buildInstallCard(
|
||||
"Warning", translate("wayland_experiment_tip"), "", () async {},
|
||||
help: 'Help',
|
||||
link: 'https://rustdesk.com/docs/en/manual/linux/#x11-required');
|
||||
} else if (bind.mainIsLoginWayland()) {
|
||||
return buildInstallCard("Warning",
|
||||
"Login screen using Wayland is not supported", "", () async {},
|
||||
help: 'Help',
|
||||
link: 'https://rustdesk.com/docs/en/manual/linux/#login-screen');
|
||||
}
|
||||
}
|
||||
if (bind.mainIsInstalledLowerVersion()) {}
|
||||
return Container();
|
||||
}
|
||||
|
||||
|
@ -16,7 +16,9 @@ def get_lang(lang):
|
||||
|
||||
def line_split(line):
|
||||
toks = line.split('", "')
|
||||
assert(len(toks) == 2)
|
||||
if len(toks) != 2:
|
||||
print(line)
|
||||
assert(0)
|
||||
k = toks[0][2:]
|
||||
v = toks[1][:-3]
|
||||
return k, v
|
||||
@ -34,7 +36,8 @@ def main():
|
||||
def expand():
|
||||
for fn in glob.glob('./src/lang/*'):
|
||||
lang = os.path.basename(fn)[:-3]
|
||||
if lang in ['en','cn']: continue
|
||||
if lang in ['en','cn']: continue
|
||||
print(lang)
|
||||
dict = get_lang(lang)
|
||||
fw = open("./src/lang/%s.rs"%lang, "wt")
|
||||
for line in open('./src/lang/cn.rs'):
|
||||
|
@ -529,6 +529,7 @@ pub fn main_get_app_name() -> String {
|
||||
pub fn main_get_app_name_sync() -> SyncReturn<String> {
|
||||
SyncReturn(get_app_name())
|
||||
}
|
||||
|
||||
pub fn main_get_license() -> String {
|
||||
get_license()
|
||||
}
|
||||
@ -1207,6 +1208,14 @@ pub fn main_on_main_window_close() {
|
||||
crate::portable_service::client::drop_portable_service_shared_memory();
|
||||
}
|
||||
|
||||
pub fn main_current_is_wayland() -> SyncReturn<bool> {
|
||||
SyncReturn(current_is_wayland())
|
||||
}
|
||||
|
||||
pub fn main_is_login_wayland() -> SyncReturn<bool> {
|
||||
SyncReturn(is_login_wayland())
|
||||
}
|
||||
|
||||
#[cfg(target_os = "android")]
|
||||
pub mod server_side {
|
||||
use jni::{
|
||||
|
Loading…
x
Reference in New Issue
Block a user