Your Android phone and your Windows PC, working as one. Local-first, end-to-end encrypted, no account.
App windows: tidy and translate the PC's errors
Bee02135e0f3750
diff --git a/desktop/app/i18n/nectarlink_zh_CN.ts b/desktop/app/i18n/nectarlink_zh_CN.tsindex b57d4d0..0cd1360 100644--- a/desktop/app/i18n/nectarlink_zh_CN.ts+++ b/desktop/app/i18n/nectarlink_zh_CN.ts@@ -3082,31 +3082,51 @@</message><message><location filename="rust_strings.h" line="69"/>+ <source>Mirroring is turned off for this phone.</source>+ <translation>已为此手机关闭镜像。</translation>+ </message>+ <message>+ <location filename="rust_strings.h" line="70"/><source>Saved %1 to Downloads\Nectarlink.</source><translation>已将 %1 保存到 Downloads\Nectarlink。</translation></message><message>- <location filename="rust_strings.h" line="70"/>+ <location filename="rust_strings.h" line="71"/><source>Screenshot copied to clipboard.</source><translation>截图已复制到剪贴板。</translation></message><message>- <location filename="rust_strings.h" line="71"/>+ <location filename="rust_strings.h" line="72"/><source>Set up Wireless debugging in NectarLink on the phone to open its apps here.</source><translation>在手机上的 NectarLink 中设置无线调试,即可在这里打开其应用。</translation></message><message>- <location filename="rust_strings.h" line="72"/>+ <location filename="rust_strings.h" line="73"/>+ <source>The app didn't open on the phone. Try again, or open NectarLink on the phone to check Wireless debugging.</source>+ <translation>应用未在手机上打开。请重试,或在手机上打开 NectarLink 检查无线调试。</translation>+ </message>+ <message>+ <location filename="rust_strings.h" line="74"/>+ <source>The phone isn't connected.</source>+ <translation>手机未连接。</translation>+ </message>+ <message>+ <location filename="rust_strings.h" line="75"/><source>The screenshot couldn't be copied to the clipboard.</source><translation>无法将截图复制到剪贴板。</translation></message><message>- <location filename="rust_strings.h" line="73"/>+ <location filename="rust_strings.h" line="76"/><source>The screenshot couldn't be saved.</source><translation>无法保存截图。</translation></message><message>- <location filename="rust_strings.h" line="74"/>+ <location filename="rust_strings.h" line="77"/>+ <source>This phone's app doesn't share its screen yet. Update NectarLink on the phone.</source>+ <translation>此手机上的应用尚不能共享屏幕。请更新手机上的 NectarLink。</translation>+ </message>+ <message>+ <location filename="rust_strings.h" line="78"/><source>Wait for the screen to appear first.</source><translation>请等待屏幕先显示出来。</translation></message>@@ -3343,7 +3363,7 @@<context><name>Notifications</name><message>- <location filename="rust_strings.h" line="75"/>+ <location filename="rust_strings.h" line="79"/><source>Code copied</source><translation>已复制验证码</translation></message>@@ -3622,17 +3642,17 @@<context><name>PhoneMic</name><message>- <location filename="rust_strings.h" line="76"/>+ <location filename="rust_strings.h" line="80"/><source>Tap Start on %1 to use its microphone.</source><translation>在 %1 上轻触“开始”以使用其麦克风。</translation></message><message>- <location filename="rust_strings.h" line="77"/>+ <location filename="rust_strings.h" line="81"/><source>The microphone is turned off for this PC on %1.</source><translation>%1 上已为此电脑关闭麦克风。</translation></message><message>- <location filename="rust_strings.h" line="78"/>+ <location filename="rust_strings.h" line="82"/><source>Update NectarLink on %1 to use its microphone.</source><translation>请更新 %1 上的 NectarLink 以使用其麦克风。</translation></message>@@ -3640,52 +3660,52 @@<context><name>Photos</name><message>- <location filename="rust_strings.h" line="79"/>+ <location filename="rust_strings.h" line="83"/><source>Copied to clipboard.</source><translation>已复制到剪贴板。</translation></message><message>- <location filename="rust_strings.h" line="80"/>+ <location filename="rust_strings.h" line="84"/><source>No recent photos found on the phone.</source><translation>手机上没有最近的照片。</translation></message><message>- <location filename="rust_strings.h" line="81"/>+ <location filename="rust_strings.h" line="85"/><source>Opening latest photo…</source><translation>正在打开最新照片…</translation></message><message>- <location filename="rust_strings.h" line="82"/>+ <location filename="rust_strings.h" line="86"/><source>Saved %1 items to %2.</source><translation>已将 %1 个项目保存到 %2。</translation></message><message>- <location filename="rust_strings.h" line="83"/>+ <location filename="rust_strings.h" line="87"/><source>Saved %1 to %2.</source><translation>已将 %1 保存到 %2。</translation></message><message>- <location filename="rust_strings.h" line="84"/>+ <location filename="rust_strings.h" line="88"/><source>That photo isn't on the phone anymore.</source><translation>该照片已不在手机上。</translation></message><message>- <location filename="rust_strings.h" line="85"/>+ <location filename="rust_strings.h" line="89"/><source>The phone doesn't share photos or files with this PC.</source><translation>手机未与此电脑共享照片或文件。</translation></message><message>- <location filename="rust_strings.h" line="86"/>+ <location filename="rust_strings.h" line="90"/><source>The phone isn't connected right now.</source><translation>手机当前未连接。</translation></message><message>- <location filename="rust_strings.h" line="87"/>+ <location filename="rust_strings.h" line="91"/><source>The photo couldn't be copied to the clipboard.</source><translation>无法将照片复制到剪贴板。</translation></message><message>- <location filename="rust_strings.h" line="88"/>+ <location filename="rust_strings.h" line="92"/><source>The photo couldn't be copied. It's in Downloads\Nectarlink.</source><translation>无法复制照片。它在 Downloads\Nectarlink 中。</translation></message>@@ -3965,32 +3985,32 @@<context><name>PlayOnPhone</name><message>- <location filename="rust_strings.h" line="89"/>+ <location filename="rust_strings.h" line="93"/><source>Connect your phone to play on it.</source><translation>请连接手机后再在其上播放。</translation></message><message>- <location filename="rust_strings.h" line="90"/>+ <location filename="rust_strings.h" line="94"/><source>Media is turned off for %1.</source><translation>已为 %1 关闭媒体。</translation></message><message>- <location filename="rust_strings.h" line="91"/>+ <location filename="rust_strings.h" line="95"/><source>Opening in %1 on %2. Tap the notification there.</source><translation>正在 %2 上用 %1 打开。请轻触那里的通知。</translation></message><message>- <location filename="rust_strings.h" line="92"/>+ <location filename="rust_strings.h" line="96"/><source>Sent to %1. Tap the notification there.</source><translation>已发送到 %1。请轻触那里的通知。</translation></message><message>- <location filename="rust_strings.h" line="93"/>+ <location filename="rust_strings.h" line="97"/><source>Tap the notification on %1 to watch.</source><translation>轻触 %1 上的通知即可观看。</translation></message><message>- <location filename="rust_strings.h" line="94"/>+ <location filename="rust_strings.h" line="98"/><source>Update NectarLink on %1 to play on it.</source><translation>请更新 %1 上的 NectarLink 以在其上播放。</translation></message>@@ -5726,77 +5746,77 @@<context><name>Timeline</name><message>- <location filename="rust_strings.h" line="95"/>+ <location filename="rust_strings.h" line="99"/><source>Copied link to clipboard.</source><translation>已将链接复制到剪贴板。</translation></message><message>- <location filename="rust_strings.h" line="96"/>+ <location filename="rust_strings.h" line="100"/><source>Copied to clipboard.</source><translation>已复制到剪贴板。</translation></message><message>- <location filename="rust_strings.h" line="97"/>+ <location filename="rust_strings.h" line="101"/><source>No phone is paired yet.</source><translation>尚未配对手机。</translation></message><message>- <location filename="rust_strings.h" line="98"/>+ <location filename="rust_strings.h" line="102"/><source>Phone microphone</source><translation>手机麦克风</translation></message><message>- <location filename="rust_strings.h" line="99"/>+ <location filename="rust_strings.h" line="103"/><source>Phone webcam</source><translation>手机摄像头</translation></message><message>- <location filename="rust_strings.h" line="100"/>+ <location filename="rust_strings.h" line="104"/><source>Screen mirroring</source><translation>屏幕镜像</translation></message><message>- <location filename="rust_strings.h" line="101"/>+ <location filename="rust_strings.h" line="105"/><source>Sending to %1…</source><translation>正在发送到 %1…</translation></message><message>- <location filename="rust_strings.h" line="102"/>+ <location filename="rust_strings.h" line="106"/><source>Sent clip to %1.</source><translation>已将剪贴内容发送到 %1。</translation></message><message>- <location filename="rust_strings.h" line="103"/>+ <location filename="rust_strings.h" line="107"/><source>That clip is no longer in clipboard history.</source><translation>该剪贴内容已不在剪贴板历史中。</translation></message><message>- <location filename="rust_strings.h" line="104"/>+ <location filename="rust_strings.h" line="108"/><source>That entry couldn't be removed. Try again.</source><translation>无法删除该条目,请重试。</translation></message><message>- <location filename="rust_strings.h" line="105"/>+ <location filename="rust_strings.h" line="109"/><source>That file was moved or deleted.</source><translation>该文件已被移动或删除。</translation></message><message>- <location filename="rust_strings.h" line="106"/>+ <location filename="rust_strings.h" line="110"/><source>That isn't a web link.</source><translation>这不是网页链接。</translation></message><message>- <location filename="rust_strings.h" line="107"/>+ <location filename="rust_strings.h" line="111"/><source>That photo was moved or deleted.</source><translation>该照片已被移动或删除。</translation></message><message>- <location filename="rust_strings.h" line="108"/>+ <location filename="rust_strings.h" line="112"/><source>The Timeline couldn't be cleared. Try again.</source><translation>无法清除时间线,请重试。</translation></message><message>- <location filename="rust_strings.h" line="109"/>+ <location filename="rust_strings.h" line="113"/><source>The photo couldn't be copied to the clipboard.</source><translation>无法将照片复制到剪贴板。</translation></message>@@ -6088,17 +6108,17 @@<context><name>Transfers</name><message>- <location filename="rust_strings.h" line="110"/>+ <location filename="rust_strings.h" line="114"/><source>Files are turned off for that device.</source><translation>已为该设备关闭文件。</translation></message><message>- <location filename="rust_strings.h" line="111"/>+ <location filename="rust_strings.h" line="115"/><source>That's too many files to send at once.</source><translation>文件太多,无法一次发送。</translation></message><message>- <location filename="rust_strings.h" line="112"/>+ <location filename="rust_strings.h" line="116"/><source>There's nothing to send in there.</source><translation>那里没有可发送的内容。</translation></message>diff --git a/desktop/app/i18n/rust_strings.h b/desktop/app/i18n/rust_strings.hindex dc1cb77..c41f59a 100644--- a/desktop/app/i18n/rust_strings.h+++ b/desktop/app/i18n/rust_strings.h@@ -66,11 +66,15 @@ static const char *const nectarlink_rust_strings[] = {QT_TRANSLATE_NOOP("Media", "That player isn't playing anymore."), // desktop/app/src/media.rsQT_TRANSLATE_NOOP("Messages", "Group texts can't be sent from the PC yet."), // desktop/app/src/messages.rsQT_TRANSLATE_NOOP("Mirror", "Couldn't start recording."), // desktop/app/src/mirror.rs+ QT_TRANSLATE_NOOP("Mirror", "Mirroring is turned off for this phone."), // desktop/app/src/mirror.rsQT_TRANSLATE_NOOP("Mirror", "Saved %1 to Downloads\\Nectarlink."), // desktop/app/src/mirror.rsQT_TRANSLATE_NOOP("Mirror", "Screenshot copied to clipboard."), // desktop/app/src/mirror.rsQT_TRANSLATE_NOOP("Mirror", "Set up Wireless debugging in NectarLink on the phone to open its apps here."), // desktop/app/src/mirror.rs+ QT_TRANSLATE_NOOP("Mirror", "The app didn't open on the phone. Try again, or open NectarLink on the phone to check Wireless debugging."), // desktop/app/src/mirror.rs+ QT_TRANSLATE_NOOP("Mirror", "The phone isn't connected."), // desktop/app/src/mirror.rsQT_TRANSLATE_NOOP("Mirror", "The screenshot couldn't be copied to the clipboard."), // desktop/app/src/mirror.rsQT_TRANSLATE_NOOP("Mirror", "The screenshot couldn't be saved."), // desktop/app/src/mirror.rs+ QT_TRANSLATE_NOOP("Mirror", "This phone's app doesn't share its screen yet. Update NectarLink on the phone."), // desktop/app/src/mirror.rsQT_TRANSLATE_NOOP("Mirror", "Wait for the screen to appear first."), // desktop/app/src/mirror.rsQT_TRANSLATE_NOOP("Notifications", "Code copied"), // desktop/app/src/notifications.rsQT_TRANSLATE_NOOP("PhoneMic", "Tap Start on %1 to use its microphone."), // desktop/app/src/phone_mic.rsdiff --git a/desktop/app/src/mirror.rs b/desktop/app/src/mirror.rsindex f20da75..a00725b 100644--- a/desktop/app/src/mirror.rs+++ b/desktop/app/src/mirror.rs@@ -935,14 +935,18 @@ fn request(window: Window, options: MirrorStart) {core_host::spawn(async move {if let Err(e) = node.mirror_start(window.device, options).await {let reason = match e {- Error::Denied => "Mirroring is turned off for this phone.".to_owned(),- Error::Unsupported if app => {- "Set up Wireless debugging in NectarLink on the phone to open its apps here.".into()- }+ Error::Denied => tr!("Mirror", "Mirroring is turned off for this phone."),+ Error::Unsupported if app => tr!(+ "Mirror",+ "Set up Wireless debugging in NectarLink on the phone to open its apps here."+ ),Error::Unsupported => {- "This phone's app doesn't share its screen yet. Update NectarLink on the phone.".into()+ tr!(+ "Mirror",+ "This phone's app doesn't share its screen yet. Update NectarLink on the phone."+ )}- Error::Offline | Error::NotPaired => "The phone isn't connected.".into(),+ Error::Offline | Error::NotPaired => tr!("Mirror", "The phone isn't connected."),e => describe(&e),};set_phase(window, Phase::Ended(Some(reason)));@@ -958,10 +962,10 @@ fn request(window: Window, options: MirrorStart) {node.mirror_stop(window.device, window.session).await;set_phase(window,- Phase::Ended(Some(- "The app didn't open on the phone. Try again, or open NectarLink on the phone to check Wireless debugging."- .into(),- )),+ Phase::Ended(Some(tr!(+ "Mirror",+ "The app didn't open on the phone. Try again, or open NectarLink on the phone to check Wireless debugging."+ ))),);}}