From 4fcf461cc6717a2c7a79f2c2ae9dcf1891859438 Mon Sep 17 00:00:00 2001 From: Zhang Sheng Date: Thu, 21 Sep 2023 15:20:51 +0800 Subject: [PATCH] fix: [audit] log isn't zh_cn Use zh_cn for burn files log Log: audit log --- .../dfmplugin-burn/utils/auditlogjob.cpp | 4 +- translations/dde-file-manager.ts | 262 +++++++------- translations/dde-file-manager_zh_CN.ts | 320 +++++++++--------- 3 files changed, 296 insertions(+), 290 deletions(-) diff --git a/src/plugins/common/dfmplugin-burn/utils/auditlogjob.cpp b/src/plugins/common/dfmplugin-burn/utils/auditlogjob.cpp index 74d56cf832..c405406e2a 100644 --- a/src/plugins/common/dfmplugin-burn/utils/auditlogjob.cpp +++ b/src/plugins/common/dfmplugin-burn/utils/auditlogjob.cpp @@ -149,10 +149,10 @@ void BurnFilesAuditLogJob::doLog(QDBusInterface &interface) void BurnFilesAuditLogJob::writeLog(QDBusInterface &interface, const QString &discPath, const QString &nativePath, qint64 size) { static const QString kLogKey { "cdrecord" }; - static const QString kLogTemplate { "ID=%1, DateTime=%2, Burner=%3, DiscType=%4, Result=%5, User=%6, FileName=%7, FileSize=%8, FileType=%9" }; + static const QString kLogTemplate { QObject::tr("ID=%1, DateTime=%2, Burner=%3, DiscType=%4, Result=%5, User=%6, FileName=%7, FileSize=%8, FileType=%9") }; static const QString &kUserName { SysInfoUtils::getUser() }; - const QString &result { burnedSuccess ? "Success" : "Failed" }; + const QString &result { burnedSuccess ? QObject::tr("Success") : QObject::tr("Failed") }; const QString &dateTime { QDateTime::currentDateTime().toString("yyyy-MM-dd hh:mm:ss") }; const QString &burner { AuditHelper::bunner(property(DeviceProperty::kDrive)) }; const QString &discType { AuditHelper::opticalMedia(property(DeviceProperty::kMedia)) }; diff --git a/translations/dde-file-manager.ts b/translations/dde-file-manager.ts index d5f1da14bb..3179c3e721 100644 --- a/translations/dde-file-manager.ts +++ b/translations/dde-file-manager.ts @@ -17,12 +17,12 @@ Application - + File Manager File Manager - + File Manager is a powerful and easy-to-use file management tool, featured with searching, copying, trash, compression/decompression, file property and other useful functions. File Manager is a powerful and easy-to-use file management tool, featured with searching, copying, trash, compression/decompression, file property and other useful functions. @@ -109,7 +109,7 @@ MimeTypeDisplayManager - + Unknown Unknown @@ -150,24 +150,24 @@ If you want to be absolutely sure it is safe to continue, contact the system administrator. - + System Disk System Disk - + Data Disk Data Disk - + Blank %1 Disc Blank %1 Disc - + @@ -175,17 +175,17 @@ Unknown - + %1 Drive %1 Drive - + %1 Encrypted %1 Encrypted - + %1 Volume %1 Volume @@ -312,12 +312,12 @@ %1 tasks in progress - + %1 item %1 item - + %1 items %1 items @@ -327,20 +327,20 @@ Unable to find the original file - + File has been moved or deleted File has been moved or deleted - + - + You do not have permission to access this folder You do not have permission to access this folder - + You do not have permission to traverse files in it You do not have permission to traverse files in it @@ -889,14 +889,14 @@ Bit - + Access denied Access denied - + Confirm button Confirm @@ -1140,8 +1140,8 @@ Unknown error - - + + Close button Close @@ -1394,7 +1394,7 @@ Edit address - + Unable to open items in the trash, please restore it first Unable to open items in the trash, please restore it first @@ -1504,7 +1504,7 @@ Searching... - + My Vault My Vault @@ -1678,6 +1678,26 @@ File is busy File is busy + + + Device disconnected + + + + + ID=%1, DateTime=%2, Burner=%3, DiscType=%4, Result=%5, User=%6, FileName=%7, FileSize=%8, FileType=%9 + ID=%1, DateTime=%2, Burner=%3, DiscType=%4, Result=%5, User=%6, FileName=%7, FileSize=%8, FileType=%9 + + + + Success + Success + + + + Failed + Failed + ddplugin_canvas::CanvasMenuScene @@ -3032,52 +3052,52 @@ dfmbase::SystemPathUtil - + Home Home - + Desktop Desktop - + Videos Videos - + Music Music - + Pictures Pictures - + Documents Documents - + Downloads Downloads - + Trash Trash - + System Disk System Disk - + Recent Recent @@ -3095,87 +3115,87 @@ create target file %1 Info failed in show conflict Info function! - + Time modified: %1 Time modified: %1 - - In data statistics - - - - + Original folder Original folder - + Contains: %1 Contains: %1 - + Original file Original file - + Size: %1 Size: %1 - + Target folder Target folder - + + In data statistics ... + + + + Target file Target file - + Syncing data Syncing data - + Please wait Please wait - + Keep both button Keep both - + Skip button Skip - - + + Replace button Replace - + Do not ask again Do not ask again - + Retry button Retry - + Merge button Merge @@ -3189,7 +3209,7 @@ Enter a password to protect shared folders - + Set a password on the shared folder for non-anonymous access Set a password on the shared folder for non-anonymous access @@ -3248,38 +3268,38 @@ dfmplugin_burn::AbstractBurnJob - + Burning disc %1, please wait... Burning disc %1, please wait... - + Writing data... Writing data... - + Verifying data... Verifying data... - - + + Data verification successful. Data verification successful. - + Burn process completed Burn process completed - + The device was not safely unmounted The device was not safely unmounted - + Disk is busy, cannot unmount now Disk is busy, cannot unmount now @@ -3297,28 +3317,10 @@ Mount error: unsupported image format - - dfmplugin_burn::BurnFilesAuditLogJob - - - ID=%1, DateTime=%2, Burner=%3, DiscType=%4, Result=%5, User=%6, FileName=%7, FileSize=%8, FileType=%9 - ID=%1, DateTime=%2, Burner=%3, DiscType=%4, Result=%5, User=%6, FileName=%7, FileSize=%8, FileType=%9 - - - - Success - Success - - - - Failed - Failed - - dfmplugin_burn::BurnISOFilesJob - + The file name or the path is too long. Please shorten the file name or the path and try again. The file name or the path is too long. Please shorten the file name or the path and try again. @@ -3326,71 +3328,71 @@ dfmplugin_burn::BurnJobManager - + OK button OK - + Disc erase failed Disc erase failed - + Burn process failed Burn process failed - + Data verification failed Data verification failed - + %1: %2 %1: %2 - + Show details Show details - + Hide details Hide details - + Error Error - + Show details button Show details - + Confirm button Confirm - + View Image File button View Image File - + Image successfully created Image successfully created - + Image creation failed Image creation failed @@ -3441,7 +3443,7 @@ dfmplugin_burn::BurnUDFFilesJob - + The file name or the path is too long. Please shorten the file name or the path and try again. The file name or the path is too long. Please shorten the file name or the path and try again. @@ -3449,12 +3451,12 @@ dfmplugin_burn::DumpISOImageJob - + Creating an ISO image Creating an ISO image - + to %1 to %1 @@ -3486,7 +3488,7 @@ dfmplugin_burn::EraseJob - + Erasing disc %1, please wait... Erasing disc %1, please wait... @@ -3559,22 +3561,22 @@ Computer - + %1 is read-only. Do you want to enable read and write permissions for it? - + Once enabled, read/write permission will be granted permanently - + Cancel Cancel - + Enable Now @@ -3638,7 +3640,7 @@ dfmplugin_computer::ProtocolEntryFileEntity - + %1 on %2 @@ -4073,7 +4075,7 @@ - Copy or Cut File failed,cause: %1 + Copy or Cut File failed, cause: %1 @@ -4111,23 +4113,23 @@ - + Failed to create the directory Failed to create the directory - + Failed to create the file - + link file error - - + + Failed to modify file permissions @@ -4434,12 +4436,12 @@ dfmplugin_propertydialog::CloseAllDialog - + Close all Close all - + Total size: %1, %2 files Total size: %1, %2 files @@ -4563,7 +4565,7 @@ - + Allow to execute as program Allow to execute as program @@ -4951,56 +4953,56 @@ dfmplugin_titlebar::ConnectToServerDialog - + Connect to Server Connect to Server - - - + + + Clear History Clear History - + Unfavorite Unfavorite - + Cancel button Cancel - + Connect button Connect - + Charset Encoding - + Default - + My Favorites My Favorites - + No favorites yet - + Favorite Favorite @@ -5855,7 +5857,7 @@ dfmplugin_vault::VaultHelper - + Vault Vault @@ -5865,7 +5867,7 @@ Vault not available because cryfs not installed! - + A task is in progress, so it cannot perform your operation A task is in progress, so it cannot perform your operation @@ -5996,22 +5998,22 @@ dfmplugin_workspace::FileViewModel - + Name Name - + Time modified Time modified - + Size Size - + Type Type diff --git a/translations/dde-file-manager_zh_CN.ts b/translations/dde-file-manager_zh_CN.ts index a6659933b7..605c6fb408 100644 --- a/translations/dde-file-manager_zh_CN.ts +++ b/translations/dde-file-manager_zh_CN.ts @@ -1,4 +1,6 @@ - + + + AccessControlDBus @@ -15,12 +17,12 @@ Application - + File Manager 文件管理器 - + File Manager is a powerful and easy-to-use file management tool, featured with searching, copying, trash, compression/decompression, file property and other useful functions. 文件管理器是一款功能强大的文件管理工具,它包括搜索、复制、回收站、压缩/解压缩,文件属性等管理功能。 @@ -107,7 +109,7 @@ MimeTypeDisplayManager - + Unknown 未知 @@ -148,24 +150,24 @@ 若想确认继续操作是否安全,请联系系统管理员。 - + System Disk 系统盘 - + Data Disk 数据盘 - + Blank %1 Disc 空白%1光盘 - + @@ -173,17 +175,17 @@ 未知 - + %1 Drive %1 驱动器 - + %1 Encrypted %1 已加密 - + %1 Volume %1 卷 @@ -310,12 +312,12 @@ 有%1个任务正在进行 - + %1 item %1 项 - + %1 items %1 项 @@ -325,20 +327,20 @@ 无法找到链接目标文件 - + File has been moved or deleted 文件已被移动或删除 - + - + You do not have permission to access this folder 您没有权限访问该文件夹 - + You do not have permission to traverse files in it 您没有权限遍历子文件 @@ -887,14 +889,14 @@ - + Access denied 禁止访问 - + Confirm button 确 定 @@ -1138,8 +1140,8 @@ 未知错误 - - + + Close button 关 闭 @@ -1392,7 +1394,7 @@ 编辑地址 - + Unable to open items in the trash, please restore it first 无法打开回收站中的项目,请先还原 @@ -1502,7 +1504,7 @@ 正在搜索... - + My Vault 我的保险箱 @@ -1676,6 +1678,26 @@ File is busy 文件繁忙 + + + Device disconnected + + + + + ID=%1, DateTime=%2, Burner=%3, DiscType=%4, Result=%5, User=%6, FileName=%7, FileSize=%8, FileType=%9 + ID=%1, 刻录时间=%2, 刻录机型号=%3, 光盘属性=%4, 刻录状态=%5, 计算机账户=%6, 文件名称=%7, 文件大小=%8, 文件类型=%9 + + + + Success + 成功 + + + + Failed + 失败 + ddplugin_canvas::CanvasMenuScene @@ -3030,52 +3052,52 @@ dfmbase::SystemPathUtil - + Home 主目录 - + Desktop 桌面 - + Videos 视频 - + Music 音乐 - + Pictures 图片 - + Documents 文档 - + Downloads 下载 - + Trash 回收站 - + System Disk 系统盘 - + Recent 最近使用 @@ -3093,87 +3115,87 @@ 在显示冲突信息功能中创建目标文件%1信息失败! - + Time modified: %1 修改时间:%1 - - In data statistics - - - - + Original folder 原始文件夹 - + Contains: %1 个数:%1 - + Original file 原始文件 - + Size: %1 大小:%1 - + Target folder 目标文件夹 - + + In data statistics ... + + + + Target file 目标文件 - + Syncing data 数据同步中 - + Please wait 请稍候 - + Keep both button 共 存 - + Skip button 跳 过 - - + + Replace button 替 换 - + Do not ask again 不再询问 - + Retry button 重 试 - + Merge button 合 并 @@ -3187,7 +3209,7 @@ 请输入共享密码 - + Set a password on the shared folder for non-anonymous access 非匿名访问必须设置共享密码 @@ -3246,38 +3268,38 @@ dfmplugin_burn::AbstractBurnJob - + Burning disc %1, please wait... 正在刻录到%1,请稍候... - + Writing data... 正在写入数据... - + Verifying data... 正在校验数据... - - + + Data verification successful. 数据验证成功。 - + Burn process completed 刻录完成 - + The device was not safely unmounted 设备没有正常卸载 - + Disk is busy, cannot unmount now 磁盘文件被占用,无法卸载 @@ -3295,28 +3317,10 @@ 挂载错误,镜像文件格式不支持 - - dfmplugin_burn::BurnFilesAuditLogJob - - - ID=%1, DateTime=%2, Burner=%3, DiscType=%4, Result=%5, User=%6, FileName=%7, FileSize=%8, FileType=%9 - ID=%1, 刻录时间=%2, 刻录机型号=%3, 光盘属性=%4, 刻录状态=%5, 计算机账户=%6, 文件名称=%7, 文件大小=%8, 文件类型=%9 - - - - Success - 成功 - - - - Failed - 失败 - - dfmplugin_burn::BurnISOFilesJob - + The file name or the path is too long. Please shorten the file name or the path and try again. 文件名或路径太长,请调整命名或路径长度后重试 @@ -3324,71 +3328,71 @@ dfmplugin_burn::BurnJobManager - + OK button 确 定 - + Disc erase failed 擦除失败 - + Burn process failed 刻录失败 - + Data verification failed 数据校验失败 - + %1: %2 %1:%2 - + Show details 显示详情 - + Hide details 隐藏详情 - + Error 错误信息 - + Show details button 显示详情 - + Confirm button 确 定 - + View Image File button 查看镜像文件 - + Image successfully created 镜像创建成功 - + Image creation failed 镜像创建失败 @@ -3439,7 +3443,7 @@ dfmplugin_burn::BurnUDFFilesJob - + The file name or the path is too long. Please shorten the file name or the path and try again. 文件名或路径太长,请调整命名或路径长度后重试 @@ -3447,12 +3451,12 @@ dfmplugin_burn::DumpISOImageJob - + Creating an ISO image 正在创建镜像文件 - + to %1 到%1 @@ -3484,7 +3488,7 @@ dfmplugin_burn::EraseJob - + Erasing disc %1, please wait... 正在擦除%1,请稍候... @@ -3557,22 +3561,22 @@ 计算机 - + %1 is read-only. Do you want to enable read and write permissions for it? %1为只读权限,是否开启读写权限? - + Once enabled, read/write permission will be granted permanently 开启后将永久获得读写权限 - + Cancel 取 消 - + Enable Now 确认开启 @@ -3636,7 +3640,7 @@ dfmplugin_computer::ProtocolEntryFileEntity - + %1 on %2 %2 上的 %1 @@ -3945,7 +3949,7 @@ Failed to move the file %1 to trash - + @@ -4022,7 +4026,7 @@ Copy or Cut File failed! - + @@ -4052,7 +4056,7 @@ Failed to move the file %1 to trash, cause: %2 - + @@ -4071,8 +4075,8 @@ - Copy or Cut File failed,cause: %1 - + Copy or Cut File failed, cause: %1 + @@ -4109,23 +4113,23 @@ 文件重命名错误 - + Failed to create the directory 目录创建失败 - + Failed to create the file 创建文件失败 - + link file error 链接文件错误 - - + + Failed to modify file permissions 修改文件权限失败 @@ -4432,12 +4436,12 @@ dfmplugin_propertydialog::CloseAllDialog - + Close all 关闭全部 - + Total size: %1, %2 files 总容量 %1,总文件数量 %2个 @@ -4561,7 +4565,7 @@ - + Allow to execute as program 允许以程序执行 @@ -4949,56 +4953,56 @@ dfmplugin_titlebar::ConnectToServerDialog - + Connect to Server 连接到服务器 - - - + + + Clear History 清除最近使用的服务器 - + Unfavorite 取消收藏 - + Cancel button 取 消 - + Connect button 连 接 - + Charset Encoding 字符集编码 - + Default 默认 - + My Favorites 我收藏的服务器 - + No favorites yet 暂无收藏 - + Favorite 收藏 @@ -5853,7 +5857,7 @@ dfmplugin_vault::VaultHelper - + Vault 保险箱 @@ -5863,7 +5867,7 @@ 因未安装cryfs,保险箱不可用 - + A task is in progress, so it cannot perform your operation 当前有任务正在进行,无法执行此操作 @@ -5994,22 +5998,22 @@ dfmplugin_workspace::FileViewModel - + Name 名称 - + Time modified 修改时间 - + Size 大小 - + Type 类型 @@ -6147,112 +6151,112 @@ Available sizes: - + Custom Size - + Device Pixel Ratio: - + Theme: - + Light - + Dark - + Mode: - + Normal - + 正常视图 Disabled - + Hovered - + Pressed - + Palette - + Current mode icon does not support the palette - + Foreground: - + Background: - + Highlight: - + HighlightForeground: - + Background Color: - + White - + Black - + Transparent - + Custom - + @@ -6302,4 +6306,4 @@ 未知专辑 - \ No newline at end of file +