mirror of
https://github.com/rustdesk/rustdesk.git
synced 2025-05-11 10:26:19 +02:00
improve cap
This commit is contained in:
parent
f0c5580f57
commit
2864e1984a
1 changed files with 14 additions and 9 deletions
|
@ -2318,16 +2318,21 @@ impl LoginConfigHandler {
|
||||||
display_name = crate::username();
|
display_name = crate::username();
|
||||||
}
|
}
|
||||||
let display_name = display_name
|
let display_name = display_name
|
||||||
.chars()
|
.split_whitespace()
|
||||||
.enumerate()
|
.map(|word| {
|
||||||
.map(|(i, c)| {
|
word.chars()
|
||||||
if i == 0 {
|
.enumerate()
|
||||||
c.to_uppercase().to_string()
|
.map(|(i, c)| {
|
||||||
} else {
|
if i == 0 {
|
||||||
c.to_string()
|
c.to_uppercase().to_string()
|
||||||
}
|
} else {
|
||||||
|
c.to_string()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.collect::<String>()
|
||||||
})
|
})
|
||||||
.collect::<String>();
|
.collect::<Vec<_>>()
|
||||||
|
.join(" ");
|
||||||
#[cfg(not(target_os = "android"))]
|
#[cfg(not(target_os = "android"))]
|
||||||
let my_platform = whoami::platform().to_string();
|
let my_platform = whoami::platform().to_string();
|
||||||
#[cfg(target_os = "android")]
|
#[cfg(target_os = "android")]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue