From ef69edb759c17ee20e37772fac464de50ffa3453 Mon Sep 17 00:00:00 2001 From: liuxinhao Date: Tue, 12 Jul 2022 15:13:24 +0800 Subject: [PATCH] update translator --- 0001-fix-translator-update-translator.patch | 6032 +++++++++++++++++++ kiran-control-panel.spec | 20 +- 2 files changed, 6049 insertions(+), 3 deletions(-) create mode 100644 0001-fix-translator-update-translator.patch diff --git a/0001-fix-translator-update-translator.patch b/0001-fix-translator-update-translator.patch new file mode 100644 index 0000000..67ca5fc --- /dev/null +++ b/0001-fix-translator-update-translator.patch @@ -0,0 +1,6032 @@ +From 047b1201db573f2899d3f4a8ccefcd17b1e877c1 Mon Sep 17 00:00:00 2001 +From: liuxinhao +Date: Tue, 12 Jul 2022 14:50:52 +0800 +Subject: [PATCH] fix(translator): update translator +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + + - 更新控制中心部分翻译 +--- + CMakeLists.txt | 17 +- + .../kiran-module-widget.cpp | 4 +- + plugins/appearance/CMakeLists.txt | 8 +- + .../kiran-cpanel-appearance.zh_CN.ts | 146 +- + plugins/keybinding/CMakeLists.txt | 4 +- + plugins/keybinding/src/main.cpp | 17 +- + .../kiran-cpanel-keybinding.zh_CN.ts | 220 +- + plugins/keyboard/CMakeLists.txt | 2 +- + .../kiran-cpanel-keyboard.zh_CN.ts | 80 +- + .../translations/kiran-cpanel-mouse.zh_CN.ts | 160 +- + plugins/timedate/CMakeLists.txt | 10 +- + .../kiran-cpanel-timedate.zh_CN.ts | 4129 +---------------- + src/main.cpp | 6 +- + translations/kiran-control-panel.zh_CN.ts | 165 +- + 14 files changed, 494 insertions(+), 4474 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 8338806..53e081a 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -26,19 +26,20 @@ configure_file(${CMAKE_SOURCE_DIR}/data/config.h.in ${CMAKE_BINARY_DIR}/config.h + configure_file(${CMAKE_SOURCE_DIR}/data/${PROJECT_NAME}.desktop.in ${CMAKE_BINARY_DIR}/${PROJECT_NAME}.desktop) + configure_file(${CMAKE_SOURCE_DIR}/data/${PROJECT_NAME}.pc.in ${CMAKE_BINARY_DIR}/${PROJECT_NAME}.pc @ONLY) + +-file(GLOB_RECURSE include "./include/*") ++file(GLOB_RECURSE INCLUDE_SRC "./include/*") + file(GLOB_RECURSE CONTROL_PANEL_SRC "./src/*") +-file(GLOB TS_FILES "../translations/*.ts") + + set(RESOURCE ./resources/control-panel-resources.qrc) #资源文件名不能与插件资源名相同,否则会导致插件中部分图片无法正常加载显示。 +-qt5_create_translation(QM_FILES ${CMAKE_SOURCE_DIR} ${TS_FILES}) ++ ++file(GLOB_RECURSE LIB_SRC "lib/*.cpp" "lib/*.h") ++set(PANEL_ALL_TRANSLATION_SRC ${INCLUDE_SRC} ${CONTROL_PANEL_SRC} ${LIB_SRC} ) ++qt5_create_translation(PANEL_QM_FILES ${PANEL_ALL_TRANSLATION_SRC} "translations/kiran-control-panel.zh_CN.ts") + + add_executable(${PROJECT_NAME} +- ${common} +- ${include} ++ ${INCLUDE_SRC} + ${CONTROL_PANEL_SRC} + ${RESOURCE} +- ${QM_FILES}) ++ ${PANEL_QM_FILES}) + + target_include_directories(${PROJECT_NAME} PRIVATE + ${CMAKE_CURRENT_BINARY_DIR} +@@ -65,13 +66,13 @@ target_link_libraries(${PROJECT_NAME} + #安装kiran-control-panel + install(TARGETS ${PROJECT_NAME} DESTINATION ${INSTALL_BINDIR}/) + #安装kiran-control-panel插件开发头文件 +-install(FILES ${include} DESTINATION ${KCP_INSTALL_INCLUDE}/) ++install(FILES ${INCLUDE_SRC} DESTINATION ${KCP_INSTALL_INCLUDE}/) + #安装kiran-control-panel.desktop + install(FILES "${CMAKE_BINARY_DIR}/${PROJECT_NAME}.desktop" DESTINATION "${INSTALL_DATADIR}/applications/") + #安装kiran-control-panel.pc文件 + install(FILES "${CMAKE_BINARY_DIR}/${PROJECT_NAME}.pc" DESTINATION "${INSTALL_LIBDIR}/pkgconfig/") + #安装kiran-control-panel翻译文件 +-install(FILES ${QM_FILES} DESTINATION ${TRANSLATION_INSTALL_DIR}) ++install(FILES ${PANEL_QM_FILES} DESTINATION ${TRANSLATION_INSTALL_DIR}) + #安装kiran-control-panel category desktop文件 + file(GLOB CATEGORY_DESKTOP "./data/category/desktop/*.desktop") + install(FILES ${CATEGORY_DESKTOP} DESTINATION ${CATEGORY_DESKTOP_INSTALL_DIR}) +diff --git a/lib/common-widgets/kiran-module-widget/kiran-module-widget.cpp b/lib/common-widgets/kiran-module-widget/kiran-module-widget.cpp +index 1fb7747..77df10b 100644 +--- a/lib/common-widgets/kiran-module-widget/kiran-module-widget.cpp ++++ b/lib/common-widgets/kiran-module-widget/kiran-module-widget.cpp +@@ -138,9 +138,9 @@ bool KiranModuleWidget::checkHasUnSaved() + if (haveUnsavedOptions) + { + auto clickedButton = KiranMessageBox::message(this, tr("Warning"), +- QString("The edited content in %1 is not saved." ++ QString(tr("The edited content in %1 is not saved." + " After switching, the edited content will be lost." +- " Are you sure you want to save?") ++ " Are you sure you want to save?")) + .arg(subItemName), + KiranMessageBox::Yes | KiranMessageBox::No); + if (clickedButton == KiranMessageBox::No) +diff --git a/plugins/appearance/CMakeLists.txt b/plugins/appearance/CMakeLists.txt +index bafe49a..72045e8 100644 +--- a/plugins/appearance/CMakeLists.txt ++++ b/plugins/appearance/CMakeLists.txt +@@ -16,15 +16,15 @@ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/appearance-config.h.in ${CMAKE_CURREN + kiran_qt5_add_dbus_interface_ex(APPEARANCE_PROXY + src/dbus-interface/com.kylinsec.Kiran.SessionDaemon.Appearance.xml + appearance_backEnd_proxy AppearanceBackEndProxy) +- +-qt5_create_translation( APPEARANCE_QM_FILES ${CMAKE_CURRENT_SOURCE_DIR} translations/kiran-cpanel-appearance.zh_CN.ts ) ++ ++qt5_create_translation( APPEARANCE_QM_FILES ${CMAKE_CURRENT_SOURCE_DIR} "translations/kiran-cpanel-appearance.zh_CN.ts" ) + + file(GLOB_RECURSE APPEARANCE_SRC + ${CMAKE_CURRENT_SOURCE_DIR}/*.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/*.h + ${CMAKE_CURRENT_SOURCE_DIR}/*.ui) + +-add_library(${TARGET_NAME} SHARED ${APPEARANCE_SRC} ${APPEARANCE_PROXY}) ++add_library(${TARGET_NAME} SHARED ${APPEARANCE_SRC} ${APPEARANCE_PROXY} ${APPEARANCE_QM_FILES}) + + target_include_directories(${TARGET_NAME} PRIVATE + src +@@ -50,7 +50,7 @@ target_link_libraries(${TARGET_NAME} + install(TARGETS ${TARGET_NAME} + DESTINATION ${PLUGIN_LIBS_INSTALL_DIR}/) + +-install(FILES ${QM_FILES} ++install(FILES ${APPEARANCE_QM_FILES} + DESTINATION ${APPEARANCE_TRANSLATIONS_DIR}) + + configure_file(${CMAKE_CURRENT_SOURCE_DIR}/kiran-cpanel-appearance.desktop.in ${CMAKE_CURRENT_BINARY_DIR}/kiran-cpanel-appearance.desktop @ONLY) +diff --git a/plugins/appearance/translations/kiran-cpanel-appearance.zh_CN.ts b/plugins/appearance/translations/kiran-cpanel-appearance.zh_CN.ts +index 01d709a..4b52d80 100644 +--- a/plugins/appearance/translations/kiran-cpanel-appearance.zh_CN.ts ++++ b/plugins/appearance/translations/kiran-cpanel-appearance.zh_CN.ts +@@ -1,37 +1,22 @@ + + + +- +- ChooserWidget +- +- +- Form +- +- +- +- +- +- +- TextLabel +- +- +- + + CursorThemes + + + Cursor Themes Settings +- ++ 光标主题设置 + + + + Faild +- ++ 失败 + + + + Set cursor themes failed! +- ++ 设置光标主题失败! + + + +@@ -39,22 +24,22 @@ + + + Form +- ++ + + + + Application Font Settings +- ++ 应用程序字体设置 + + + + Titlebar Font Settings +- ++ 窗口标题字体设置 + + + + Monospace Font Settings +- ++ 等宽字体设置 + + + +@@ -62,22 +47,22 @@ + + + Form +- ++ + + + + Icon Themes Setting +- ++ 图标主题设置 + + + + Faild +- ++ 失败 + + + + Set icon themes failed! +- ++ 设置图标主题失败! + + + +@@ -85,22 +70,22 @@ + + + Add Image Failed +- ++ 添加壁纸失败 + + + + The image already exists! +- ++ 该壁纸已存在! + + + + Delete image +- ++ 删除壁纸 + + + + Are you sure you want to delete this picture? +- ++ 您确定要删除此壁纸? + + + +@@ -108,22 +93,22 @@ + + + KiranCpanelAppearance +- ++ + + + + Wallpaper Setting +- ++ 壁纸设置 + + + + Theme Setting +- ++ 主题设置 + + + + Font Setting +- ++ 字体设置 + + + +@@ -133,45 +118,60 @@ + + + Failed +- ++ 失败 + + + + Set font failed! +- ++ 设置字体失败! + + + + Get icon themes failed! +- ++ 获取图标主题失败! + + + + Get cursor themes failed! +- ++ 获取光标主题失败! + + + + Warning +- ++ 警告 + + + + There is no theme to set! ++ 目前没有主题可以设置! ++ ++ ++ ++ SettingBriefWidget ++ ++ ++ Form ++ ++ ++ ++ ++ ++ ++ TextLabel + + + + + ThemeWidget + +- ++ + Dark Theme +- ++ 深色主题 + + +- ++ + Light Theme +- ++ 浅色主题 + + + +@@ -179,38 +179,38 @@ + + + Form +- ++ + + + + Dark and Light Theme +- ++ 深浅色主题设置 + + + + Themes Settings +- ++ 主题设置 + + + + Open Window Effects +- ++ 打开或关闭窗口特效 + + + + Choose icon themes +- ++ 选择图标主题 + + + + + Unknown +- ++ 未知 + + + + Choose cursor themes +- ++ 选择光标主题 + + + +@@ -218,74 +218,74 @@ + + + Form +- ++ + + + + Set wallpaper +- ++ 壁纸设置 + + + + Desktop Wallpaper Preview +- ++ 桌面壁纸预览 + + + + Lock Screen WallPaper Preview +- ++ 锁屏壁纸预览 + + + + Select wallpaper +- ++ 选择壁纸 + + + + Select Wallpaper +- ++ 选择壁纸 + + +- ++ + Set Desktop Wallpaper +- ++ 选择桌面壁纸 + + +- ++ + Set Lock Screen Wallpaper +- ++ 选择锁屏壁纸 + + +- +- ++ ++ + set wallpaper +- ++ 壁纸设置 + + +- +- ++ ++ + Set wallpaper failed! +- ++ 壁纸设置失败! + + +- ++ + select picture +- ++ 选择图片 + + +- ++ + image files(*.bmp *.jpg *.png *.tif *.gif *.pcx *.tga *.exif *.fpx *.svg *.psd *.cdr *.pcd *.dxf *.ufo *.eps *.ai *.raw *.WMF *.webp) + + + +- ++ + Add Image Failed +- ++ 添加壁纸失败 + + +- ++ + The image already exists! +- ++ 该壁纸已存在! + + + +diff --git a/plugins/keybinding/CMakeLists.txt b/plugins/keybinding/CMakeLists.txt +index 01a97cb..0368c82 100644 +--- a/plugins/keybinding/CMakeLists.txt ++++ b/plugins/keybinding/CMakeLists.txt +@@ -41,8 +41,8 @@ target_link_libraries(${TARGET_NAME} + install(TARGETS ${TARGET_NAME} + DESTINATION ${PLUGIN_LIBS_INSTALL_DIR}/) + +-install(FILES ${QM_FILES} +- DESTINATION ${TRANSLATIONS_DIR}) ++install(FILES ${KEYBINDING_QM_FILES} ++ DESTINATION ${INSTALL_DATADIR}/kiran-cpanel-keybinding/translations/) + + configure_file (${CMAKE_CURRENT_SOURCE_DIR}/data/kiran-cpanel-keybinding.desktop.in ${CMAKE_CURRENT_BINARY_DIR}/kiran-cpanel-keybinding.desktop) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/kiran-cpanel-keybinding.desktop DESTINATION ${PLUGIN_DESKTOP_INSTALL_DIR}/) +\ No newline at end of file +diff --git a/plugins/keybinding/src/main.cpp b/plugins/keybinding/src/main.cpp +index 106ba18..f316402 100644 +--- a/plugins/keybinding/src/main.cpp ++++ b/plugins/keybinding/src/main.cpp +@@ -45,7 +45,21 @@ public: + KLOG_INFO() << "Connect keybinding dbus service failed!"; + return -1; + } +- //TODO:统一修改翻译文件的加载路径 ++ m_translator = new QTranslator; ++ if (!m_translator->load(QLocale(), ++ "kiran-cpanel-keybinding", ++ ".", ++ "/usr/share/kiran-cpanel-keybinding/translations/", ++ ".qm")) ++ { ++ KLOG_DEBUG() << "Kiran cpanel keybinding load translation failed"; ++ m_translator->deleteLater(); ++ m_translator = nullptr; ++ } ++ else ++ { ++ QCoreApplication::installTranslator(m_translator); ++ } + return 0; + }; + +@@ -102,6 +116,7 @@ public: + + private: + QWidget* m_currentWidget = nullptr; ++ QTranslator* m_translator = nullptr; + }; + + #include "main.moc" +\ No newline at end of file +diff --git a/plugins/keybinding/translation/kiran-cpanel-keybinding.zh_CN.ts b/plugins/keybinding/translation/kiran-cpanel-keybinding.zh_CN.ts +index c57c397..13c3edf 100644 +--- a/plugins/keybinding/translation/kiran-cpanel-keybinding.zh_CN.ts ++++ b/plugins/keybinding/translation/kiran-cpanel-keybinding.zh_CN.ts +@@ -6,12 +6,12 @@ + + + None +- ++ 暂无 + + + + disabled +- ++ 禁用 + + + +@@ -19,87 +19,87 @@ + + + Audio Play +- ++ 音频播放 + + + + Search +- ++ 搜索 + + + + WWW +- ++ 万维网 + + + + Audio Lower Volume +- ++ 减小音量 + + + + Audio Raise Volume +- ++ 增大音量 + + + + Mic Mute +- ++ 输入静音 + + + + Audio Stop +- ++ 音频停止 + + + + Explorer +- ++ 浏览 + + + + Calculator +- ++ 计算器 + + + + Audio Mute +- ++ 音频暂停 + + + + Audio Pause +- ++ 音频暂停 + + + + Audio Prev +- ++ 音频上一个 + + + + Audio Media +- ++ 音频媒体 + + + + Audio Next +- ++ 音频下一个 + + + + Mail +- ++ 邮件 + + + + Tools +- ++ 工具 + + + + Eject +- ++ 弹出 + + + +@@ -107,201 +107,201 @@ + + + Form +- ++ + + +- ++ + Custom +- ++ 自定义 + + +- +- +- ++ ++ ++ + Edit +- ++ 编辑 + + +- +- +- +- ++ ++ ++ ++ + Add +- ++ 添加 + + +- ++ + Reset +- ++ 重置 + + +- ++ + Custom Shortcut Name +- ++ 自定义快捷键名称 + + +- ++ + Custom Shortcut application +- ++ 自定义快捷键应用程序 + + +- ++ + Custom Shortcut Key +- ++ 自定义快捷键 + + +- ++ + Cancel +- ++ 取消 + + +- ++ + Shortcut Name +- ++ 快捷键名称 + + +- ++ + Shortcut application +- ++ 快捷键应用程序 + + +- ++ + Shortcut key +- ++ 快捷键 + + +- ++ + Save +- ++ 保存 + + +- ++ + return +- ++ 返回 + + +- ++ + Please enter a search keyword... +- ++ 请输入搜索关键字... + + +- ++ + Required +- ++ 必填 + + +- +- ++ ++ + Please press the new shortcut key +- ++ 请输入新快捷键 + + +- ++ + Finished +- ++ 完成 + + +- +- +- +- +- +- +- ++ ++ ++ ++ ++ ++ ++ + Failed +- ++ 失败 + + +- ++ + Get shortcut failed,error: +- ++ 获取快捷键失败,错误: + + +- ++ + failed to load shortcut key data! +- ++ 加载快捷键数据失败! + + +- ++ + List shortcut failed,error:%1 +- ++ 列出快捷键失败,错误:%1 + + +- ++ + Error +- ++ 错误 + + +- ++ + Open File +- ++ 打开文件 + + +- ++ + System +- ++ 系统 + + +- ++ + Sound +- ++ 声音 + + +- ++ + Delete shortcut failed,error: +- ++ 删除快捷键失败,错误: + + +- +- ++ ++ + Warning +- ++ 警告 + + +- +- ++ ++ + Please complete the shortcut information! +- ++ 请完善快捷键信息! + + +- ++ + Set shortcut +- ++ 设置快捷键 + + +- ++ + Are you sure you want to disable this shortcut? +- ++ 是否确定要禁用此快捷键? + + +- ++ + Modify system shortcut failed,error: +- ++ 修改系统快捷键失败,错误: + + +- ++ + Modify custom shortcut failed,error: +- ++ 修改自定义快捷键失败,错误: + + +- ++ + Add custom shortcut failed,error: +- ++ 添加自定义快捷键失败,错误: + + +- ++ + Reset shortcut failed,error: +- ++ 重置快捷键失败,错误: + + +- ++ + Cannot use shortcut "%1", Because you cannot enter with this key.Please try again using Ctrl, Alt, or Shift at the same time. +- ++ 无法使用快捷键"%1",因为使用此键将无法输入,请同时使用Ctrl,Alt,Shift再试一次。 + + +- ++ + Shortcut keys %1 are already used in %2,Please try again! +- ++ 快捷键%1已用于%2,请再试一次! + + + +@@ -309,13 +309,13 @@ + + + Form +- ++ + + + + + TextLabel +- ++ + + + +@@ -323,12 +323,12 @@ + + + Failed +- ++ 失败 + + + + List shortcut failed,error: +- ++ 列出快捷键失败,错误: + + + +diff --git a/plugins/keyboard/CMakeLists.txt b/plugins/keyboard/CMakeLists.txt +index 6a29efc..7d8336f 100644 +--- a/plugins/keyboard/CMakeLists.txt ++++ b/plugins/keyboard/CMakeLists.txt +@@ -50,5 +50,5 @@ install(TARGETS ${TARGET_NAME} + install(FILES data/kiran-cpanel-keyboard.desktop + DESTINATION ${PLUGIN_DESKTOP_INSTALL_DIR}/) + +-install(FILES ${QM_FILES} ++install(FILES ${KEYBOARD_QM} + DESTINATION ${INSTALL_DATADIR}/kiran-cpanel-keyboard/translations/) +diff --git a/plugins/keyboard/translation/kiran-cpanel-keyboard.zh_CN.ts b/plugins/keyboard/translation/kiran-cpanel-keyboard.zh_CN.ts +index 2884c45..afb18f2 100644 +--- a/plugins/keyboard/translation/kiran-cpanel-keyboard.zh_CN.ts ++++ b/plugins/keyboard/translation/kiran-cpanel-keyboard.zh_CN.ts +@@ -6,7 +6,7 @@ + + + Form +- ++ + + + +@@ -14,53 +14,53 @@ + + + Form +- ++ + + + + Repeat Key +- ++ 重复键 + + + + (Repeat a key while holding it down) +- ++ (按住某一键时重复该键) + + + + Delay +- ++ 延时 + + + + Short +- ++ + + + + Long +- ++ + + + + Interval +- ++ 速度 + + + + Slow +- ++ + + + + Fast +- ++ + + + + + Enter characters to test the settings +- ++ 输入字符来测试设置 + + + +@@ -68,7 +68,7 @@ + + + Form +- ++ + + + +@@ -76,7 +76,7 @@ + + + LayoutList +- ++ + + + +@@ -84,80 +84,80 @@ + + + Form +- ++ + + + + Select Kayboard Layout +- ++ 选择布局 + + + +- ++ + Edit +- ++ 编辑 + + + +- ++ + Add Layout +- ++ 添加布局 + + + + Addition +- ++ 添加 + + + + Return +- ++ 返回 + + +- +- +- +- ++ ++ ++ ++ + Failed +- ++ 失败 + + +- ++ + You have added this keyboard layout! +- ++ 您已经添加过该布局 + + +- ++ + The %1 keyboard layout does not exist! +- ++ 该 %1 键盘布局不存在! + + +- ++ + The keyboard layout is currently in use and cannot be deleted! +- ++ 该布局目前正在使用,无法删除! + + +- ++ + Delete Layout +- ++ 删除布局 + + +- ++ + You do not appear to have added %1 keyboard layout! +- ++ 您似乎没有添加 %1 键盘布局! + + +- ++ + Finish +- ++ 完成 + + + + QObject + +- ++ + No search results, please search again... +- ++ 无搜索结果,请重新搜索... + + + +diff --git a/plugins/mouse/translations/kiran-cpanel-mouse.zh_CN.ts b/plugins/mouse/translations/kiran-cpanel-mouse.zh_CN.ts +index 39cc633..e071184 100644 +--- a/plugins/mouse/translations/kiran-cpanel-mouse.zh_CN.ts ++++ b/plugins/mouse/translations/kiran-cpanel-mouse.zh_CN.ts +@@ -1,41 +1,6 @@ + + + +- +- CreateUserPage +- +- Cancel +- 取消 +- +- +- +- CursorThemes +- +- Faild +- 失败 +- +- +- +- IconThemes +- +- Faild +- 失败 +- +- +- +- KcpInterface +- +- warning +- 警告 +- +- +- +- KiranAvatarEditor +- +- Cancel +- 取消 +- +- + + KiranCPanelMouse + +@@ -149,41 +114,60 @@ + Fast + 快速 + ++ ++ ++ Form ++ ++ + + + MousePage + + ++ ++ + Form + + + + ++ ++ + Select Mouse Hand + 选择鼠标手持模式 + + + ++ ++ + Mouse Motion Acceleration + 鼠标移动加速 + + + ++ ++ + Slow + + + + ++ ++ + Fast + + + + ++ ++ + Natural Scroll + 是否为自然滚动 + + + ++ ++ + Middle Emulation Enabled + 同时按下左右键模拟中键 + +@@ -201,20 +185,29 @@ + + MouseSettings + ++ ++ Form ++ ++ ++ ++ + Select Mouse Hand +- 选择鼠标手持模式 ++ 选择鼠标手持模式 + + ++ + Mouse Motion Acceleration +- 鼠标移动加速 ++ 鼠标移动加速 + + ++ + Natural Scroll +- 是否为自然滚动 ++ 是否为自然滚动 + + ++ + Middle Emulation Enabled +- 同时按下左右键模拟中键 ++ 同时按下左右键模拟中键 + + + Right Hand Mode +@@ -225,16 +218,18 @@ + 左手模式 + + ++ + Slow +- ++ + + + Standard + 标准 + + ++ + Fast +- ++ + + + +@@ -268,75 +263,82 @@ + 加载qss文件失败! + + +- +- Shortcut +- +- Reset +- 重置 +- +- +- Cancel +- 取消 +- +- +- Save +- 保存 +- +- + + TouchPadPage + + ++ ++ + Form + + + + ++ ++ + TouchPad Enabled + 开启触摸板 + + + ++ ++ + Select TouchPad Hand + 选择触摸板使用模式 + + + ++ ++ + TouchPad Motion Acceleration + 触摸板移动加速 + + + ++ ++ + Slow + + + + ++ ++ + Fast + + + + ++ ++ + Select Click Method + 设置点击触摸板方式 + + + ++ ++ + Select Scroll Method + 滚动窗口方式 + + + ++ ++ + Natural Scroll + 是否为自然滚动 + + + ++ ++ + Enabled while Typing + 打字时触摸板禁用 + + + ++ ++ + Tap to Click + 轻击(不按下)触摸板功能是否生效 + +@@ -382,48 +384,63 @@ + 禁用触摸板 + + ++ ++ Form ++ ++ ++ ++ + TouchPad Enabled +- 开启触摸板 ++ 开启触摸板 + + ++ + Select TouchPad Hand +- 选择触摸板使用模式 ++ 选择触摸板使用模式 + + ++ + TouchPad Motion Acceleration +- 触摸板移动加速 ++ 触摸板移动加速 + + ++ + Select Click Method +- 设置点击触摸板方式 ++ 设置点击触摸板方式 + + ++ + Select Scroll Method +- 滚动窗口方式 ++ 滚动窗口方式 + + ++ + Natural Scroll +- 是否为自然滚动 ++ 是否为自然滚动 + + ++ + Enabled while Typing +- 打字时触摸板禁用 ++ 打字时触摸板禁用 + + ++ + Tap to Click +- 轻击(不按下)触摸板功能是否生效 ++ 轻击(不按下)触摸板功能是否生效 + + ++ + Slow +- ++ + + + Standard + 标准 + + ++ + Fast +- ++ + + + Right Hand Mode +@@ -450,15 +467,4 @@ + 边缘滑动 + + +- +- UserInfoPage +- +- Save +- 保存 +- +- +- Cancel +- 取消 +- +- + +diff --git a/plugins/timedate/CMakeLists.txt b/plugins/timedate/CMakeLists.txt +index de54a93..02805dc 100644 +--- a/plugins/timedate/CMakeLists.txt ++++ b/plugins/timedate/CMakeLists.txt +@@ -12,14 +12,14 @@ pkg_search_module(KIRAN_STYLE_HELPER REQUIRED kiran-style-helper) + file(GLOB_RECURSE SRC + "src/*.cpp" + "src/*.h") +- ++ + include_directories("${CMAKE_BINARY_DIR}" "src" ) +-qt5_create_translation( QM_FILES ${CMAKE_SOURCE_DIR} translations/kiran-cpanel-timedate.zh_CN.ts ) ++qt5_create_translation( TIMEDATE_QM_FILES ${CMAKE_CURRENT_SOURCE_DIR} "translations/kiran-cpanel-timedate.zh_CN.ts" ) + + add_library(${TARGET_NAME} SHARED + ${SRC} + ${QRC} +- ${QM_FILES}) ++ ${TIMEDATE_QM_FILES}) + + target_include_directories(${TARGET_NAME} PRIVATE + include +@@ -54,6 +54,6 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/kiran-cpanel-timedate.desktop DESTINAT + install(TARGETS ${TARGET_NAME} DESTINATION ${PLUGIN_LIBS_INSTALL_DIR}) + + #安装翻译文件 +-set(TRANSLATE_INSTALL_DIR ${INSTALL_DATADIR}/${PROJECT_NAME}/translations/) ++set(TRANSLATE_INSTALL_DIR ${INSTALL_DATADIR}/${TARGET_NAME}/translations/) + configure_file(./config/config.h.in ${CMAKE_CURRENT_BINARY_DIR}/kcp-timedate-config.h @ONLY) +-install(FILES ${QM_FILES} DESTINATION ${TRANSLATE_INSTALL_DIR} ) ++install(FILES ${TIMEDATE_QM_FILES} DESTINATION ${TRANSLATE_INSTALL_DIR} ) +diff --git a/plugins/timedate/translations/kiran-cpanel-timedate.zh_CN.ts b/plugins/timedate/translations/kiran-cpanel-timedate.zh_CN.ts +index 5f5c6df..8aabda0 100644 +--- a/plugins/timedate/translations/kiran-cpanel-timedate.zh_CN.ts ++++ b/plugins/timedate/translations/kiran-cpanel-timedate.zh_CN.ts +@@ -2,4094 +2,235 @@ + + + +- AccountItemWidget +- +- +- +- +- Form +- +- +- +- +- +- +- Tom Hardy +- +- +- +- +- Create new user +- +- +- +- +- disable +- +- +- +- +- enable +- +- +- +- +- AdvanceSettings +- +- +- +- +- Form +- +- +- +- +- +- +- Login shell +- +- +- +- +- +- +- Specify user id +- +- +- +- +- +- +- Specify user home +- +- +- +- +- +- +- confirm +- +- +- +- +- +- +- cancel +- +- ++ DateTimeSettings + +- +- Advance Settings +- ++ ++ ++ ++ DateTimeSettings ++ 日期时间设置 + + +- +- +- Automatically generated by system +- ++ ++ ++ ++ Select Time ++ 选择时间 + + +- +- Please enter the correct path +- ++ ++ ++ ++ Select Date ++ 选择日期 + + +- +- Please enter specify user Id +- ++ ++ ++ ++ save ++ 保存 + + +- +- Please enter the correct home directory +- ++ ++ ++ ++ reset ++ 重置 + + + +- AudioSystemTray +- +- +- Volume Setting +- +- ++ DaySpinBox + +- +- Mixed Setting +- ++ ++ %1 ++ %1日 + + + +- AuthManagerPage +- +- +- +- +- AuthManagerPage +- +- +- +- +- +- +- Fingerprint Authentication +- +- +- +- +- +- +- Face Authentication +- +- +- +- +- +- +- Password Authentication +- +- +- +- +- +- +- save +- 保存 +- ++ DisplayFormatSettings + +- +- +- +- return +- ++ ++ ++ ++ DisplayFormatSettings ++ 日期时间格式设置 + + +- +- add fingerprint +- ++ ++ ++ ++ Long date display format ++ 长日期显示格式 + + +- +- add face +- ++ ++ ++ ++ Short date display format ++ 短日期显示格式 + + +- +- +- error +- ++ ++ ++ ++ Time format ++ 时间格式 + + +- +- +- please ensure that at least one authentication option exists +- ++ ++ ++ ++ Show time witch seconds ++ 时间显示秒 + + +- +- fingerprint_ +- ++ ++ 24-hours ++ 二十四小时制 + + +- +- face_ +- ++ ++ 12-hours ++ 十二小时制 + + + +- BatterySettingsPage +- +- +- +- +- BatterySettingsPage +- +- +- +- +- +- +- After idle for more than the following time, the computer will execute +- +- +- +- +- +- +- When the battery is lit up, it will be executed +- +- +- +- +- +- +- The monitor will turn off when it is idle +- +- +- +- +- +- +- Reduce screen brightness when idle +- +- +- +- +- Display Off +- +- +- +- +- +- Suspend +- +- +- +- +- +- Shutdown +- +- +- +- +- +- Hibernate +- +- ++ KiranDatePickerWidget + +- +- +- Do nothing ++ ++ ++ ++ Form + + + + +- BiometricItem ++ KiranTimeDateWidget + +- +- +- +- BiometricItem ++ ++ ++ ++ KiranTimeDateWidget + + + +- +- +- +- text +- ++ ++ ++ ++ Automatic synchronizetion ++ 自动同步 + + +- +- +- +- add +- ++ ++ Change Time Zone ++ 更改时区 + +- +- +- CPanelAudioWidget + +- +- +- +- CPanelAudioWidget +- ++ ++ Set Time Manually ++ 手动设置时间 + + +- +- Output +- ++ ++ Time date format setting ++ 日期时间格式设置 + + +- +- Input +- ++ ++ %1(%2) ++ %1时间(%2) + + + +- CPanelNetworkWidget ++ KiranTimePickerWidget + +- +- +- CPanelNetworkWidget ++ ++ ++ ++ Form + + + + +- CPanelPowerWidget +- +- +- +- +- CPanelPowerWidget +- +- +- +- +- General Settings +- +- ++ KiranTimeZone + +- +- Power Settings ++ ++ ++ ++ Form + + + +- +- Battery Settings +- ++ ++ Search in all time zones... ++ 在所有时区中搜索... + + + +- ChangeHostNameWidget ++ KiranTimeZoneItem + +- +- ++ ++ ++ + Form + + + +- +- +- Host Name: +- +- +- +- +- +- Save +- +- +- +- +- +- Cancel +- +- +- +- +- Host Name +- +- +- +- +- Warning +- +- +- +- +- Change host name failed! Please check the Dbus service! +- ++ ++ No search results, please search again... ++ 无搜索结果,请重新搜索... + + + +- ChooseItem ++ KiranTimeZoneList + +- +- ++ ++ ++ + Form + + + + +- ConnectionDetailsWidget +- +- +- ConnectionDetailsWidget +- +- +- +- +- Security type +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- +- TextLabel +- +- +- +- +- Frequency band +- +- +- +- +- Channel +- +- +- +- +- Interface +- +- +- +- +- MAC +- +- +- +- +- IPv4 +- +- +- +- +- +- Gateway +- +- +- +- +- Preferred DNS +- +- +- +- +- Subnet mask +- +- +- +- +- IPv6 +- +- +- +- +- Prefix +- +- ++ MonthSpinBox + +- +- Rate +- ++ ++ MMMM ++ MMMM + + + +- ConnectionLists +- +- +- Tips +- +- ++ TimezoneSettings + +- +- Please input a network name ++ ++ ++ ++ TimezoneSettings + + + +- +- +- Other WiFi networks +- ++ ++ ++ ++ Select Time Zone ++ 选择时区 + +- +- +- ConnectionShowPage + +- +- +- ConnectionShowPage +- ++ ++ ++ ++ save ++ 保存 + + +- +- +- TextLabel +- +- +- +- +- +- Create +- +- +- +- +- CreateUserPage +- +- +- +- +- Form +- +- +- +- +- +- +- User name +- +- +- +- +- +- +- User type +- +- +- +- +- +- +- Password +- +- +- +- +- +- +- Confirm password +- +- +- +- +- +- +- Advance setting +- +- +- +- +- +- +- Confirm +- +- +- +- +- +- +- Cancel +- +- +- +- +- standard +- +- +- +- +- administrator +- +- +- +- +- Please enter user name first +- +- +- +- +- Please enter your user name +- +- +- +- +- user name cannot be a pure number +- +- +- +- +- user name already exists +- +- +- +- +- Please enter your password +- +- +- +- +- Please enter the password again +- +- +- +- +- The password you enter must be the same as the former one +- +- +- +- +- +- Error +- +- +- +- +- Password encryption failed +- +- +- +- +- CursorThemes +- +- +- Cursor Themes Settings +- +- +- +- +- Faild +- +- +- +- +- Set cursor themes failed! +- +- +- +- +- DateTimeSettings +- +- +- +- +- DateTimeSettings +- 日期时间设置 +- +- +- +- +- +- Select Time +- 选择时间 +- +- +- +- +- +- Select Date +- 选择日期 +- +- +- +- +- +- save +- 保存 +- +- +- +- +- ++ ++ ++ + reset + 重置 + + +- +- DaySpinBox +- +- +- %1 +- %1日 +- +- +- +- DetailsPage +- +- +- DetailsPage +- +- +- +- +- Network Details +- +- +- +- +- Please select a connection +- +- +- +- +- DisconnectAndDeleteButton +- +- +- +- DisconnectAndDeleteButton +- +- +- +- +- +- Disconnect +- +- +- +- +- +- Delete +- +- +- +- +- Are you sure you want to delete the connection %1 +- +- +- +- +- Warning +- +- +- +- +- DisplayFormatSettings +- +- +- +- +- DisplayFormatSettings +- 日期时间格式设置 +- +- +- +- +- +- Long date display format +- 长日期显示格式 +- +- +- +- +- +- Short date display format +- 短日期显示格式 +- +- +- +- +- +- Time format +- 时间格式 +- +- +- +- +- +- Show time witch seconds +- 时间显示秒 +- +- +- +- 24-hours +- 二十四小时制 +- +- +- +- 12-hours +- 十二小时制 +- +- +- +- DnsWidget +- +- +- +- DnsWidget +- +- +- +- +- +- Preferred DNS +- +- +- +- +- +- Alternate DNS +- +- +- +- +- DslManager +- +- +- +- DslManager +- +- +- +- +- DSL +- +- +- +- +- DslSettingPage +- +- +- +- DslSettingPage +- +- +- +- +- +- Save +- +- +- +- +- +- Return +- +- +- +- +- EthernetWidget +- +- +- +- EthernetWidget +- +- +- +- +- +- MAC Address Of Ethernet Device +- +- +- +- +- +- Ethernet Clone MAC Address +- +- +- +- +- +- Custom MTU +- +- +- +- +- No device specified +- +- +- +- +- FaceEnrollDialog +- +- +- +- +- FaceEnrollDialog +- +- +- +- +- +- +- balabalalbala... +- +- +- +- +- +- +- save +- 保存 +- +- +- +- +- +- cancel +- +- +- +- +- initializing face collection environment... +- +- +- +- +- failed to initialize face collection environment! +- +- +- +- +- +- Failed to start collection +- +- +- +- +- FingerprintEnrollDialog +- +- +- +- +- FingerprintEnrollDialog +- +- +- +- +- +- +- balabalalbala... +- +- +- +- +- +- +- save +- 保存 +- +- +- +- +- +- cancel +- +- +- +- +- Finger Enroll +- +- +- +- +- This fingerprint is bound to the user(%1) +- +- +- +- +- Info +- +- +- +- +- Error +- +- +- +- +- FingerprintInputWorker +- +- +- initializing fingerprint collection environment... +- +- +- +- +- Fonts +- +- +- +- Form +- +- +- +- +- +- Application Font Settings +- +- +- +- +- +- Titlebar Font Settings +- +- +- +- +- +- Monospace Font Settings +- +- +- +- +- GeneralPage +- +- +- +- Form +- +- +- +- +- +- Repeat Key +- +- +- +- +- +- (Repeat a key while holding it down) +- +- +- +- +- +- Delay +- +- +- +- +- +- Short +- +- +- +- +- +- Long +- +- +- +- +- +- Interval +- +- +- +- +- +- Slow +- +- +- +- +- +- Fast +- +- +- +- +- +- +- Enter characters to test the settings +- +- +- +- +- GeneralSettingsPage +- +- +- +- +- GeneralSettingsPage +- +- +- +- +- +- +- When the power button is pressed +- +- +- +- +- +- +- When the suspend button is pressed +- +- +- +- +- +- +- When closing the lid +- +- +- +- +- +- +- Display brightness setting +- +- +- +- +- +- +- 0% +- +- +- +- +- +- +- Regard computer as idle after +- +- +- +- +- +- +- Lock screen when idle +- +- +- +- +- +- shutdown +- +- +- +- +- +- +- hibernate +- +- +- +- +- +- +- suspend +- +- +- +- +- +- display off +- +- +- +- +- +- +- do nothing +- +- +- +- +- ERROR +- +- +- +- +- %1hour +- +- +- +- +- %1minute +- +- +- +- +- GeneralWidget +- +- +- +- GeneralWidget +- +- +- +- +- +- TextLabel +- +- +- +- +- +- Auto Connection +- +- +- +- +- Wired Connection %1 +- +- +- +- +- VPN L2TP %1 +- +- +- +- +- VPN PPTP %1 +- +- +- +- +- HardWorker +- +- +- Create User failed +- +- +- +- +- update password failed +- +- +- +- +- icon file +- +- +- +- +- userName type +- +- +- +- +- locked +- +- +- +- +- Failed to update user properties,%1 +- +- +- +- +- Failed to delete user,%1 +- +- +- +- +- HardwareInformation +- +- +- +- Form +- +- +- +- +- +- CPU: +- +- +- +- +- +- +- +- TextLabel +- +- +- +- +- +- Memory: +- +- +- +- +- +- Hard disk: +- +- +- +- +- +- Graphics card: +- +- +- +- +- +- Network card: +- +- +- +- +- +- +- Unknow +- +- +- +- +- IconThemes +- +- +- +- Form +- +- +- +- +- +- Icon Themes Setting +- +- +- +- +- Faild +- +- +- +- +- Set icon themes failed! +- +- +- +- +- ImageSelector +- +- +- Add Image Failed +- +- +- +- +- The image already exists! +- +- +- +- +- Delete image +- +- +- +- +- Are you sure you want to delete this picture? +- +- +- +- +- InputDialog +- +- +- InputDialog +- +- +- +- +- +- TextLabel +- +- +- +- +- Confirm +- +- +- +- +- Cancel +- +- +- +- +- InputPage +- +- +- +- +- InputPage +- +- +- +- +- +- +- Input devices +- +- +- +- +- +- +- Input volume +- +- +- +- +- +- +- Feedback volume +- +- +- +- +- No input device detected +- +- +- +- +- Ipv4Widget +- +- +- +- Ipv4Widget +- +- +- +- +- +- IPV4 Method +- +- +- +- +- +- IP Address +- +- +- +- +- +- Net Mask +- +- +- +- +- +- Gateway +- +- +- +- +- +- Preferred DNS +- +- +- +- +- +- Alternate DNS +- +- +- +- +- Auto +- +- +- +- +- Manual +- +- +- +- +- Ipv6Widget +- +- +- +- Ipv6Widget +- +- +- +- +- +- IPV6 Method +- +- +- +- +- +- IP Address +- +- +- +- +- +- Prefix +- +- +- +- +- +- Gateway +- +- +- +- +- +- Preferred DNS +- +- +- +- +- +- Alternate DNS +- +- +- +- +- Auto +- +- +- +- +- Manual +- +- +- +- +- Ignored +- +- +- +- +- KeycodeTranslator +- +- +- None +- +- +- +- +- disabled +- +- +- +- +- KiranAccountManager +- +- +- +- disable +- +- +- +- +- +- enable +- +- +- +- +- Create new user +- +- +- +- +- KiranAvatarEditor +- +- +- Avatar Editor +- +- +- +- +- Confirm +- +- +- +- +- Cancel +- +- +- +- +- KiranCpanelAppearance +- +- +- +- KiranCpanelAppearance +- +- +- +- +- Wallpaper Setting +- +- +- +- +- Theme Setting +- +- +- +- +- Font Setting +- +- +- +- +- KiranDatePickerWidget +- +- +- +- +- Form +- +- +- +- +- KiranDisplayConfiguration +- +- +- +- KiranDisplayConfiguration +- +- +- +- +- +- Copy display +- +- +- +- +- +- Extended display +- +- +- +- +- +- +- +- Resolution ratio +- +- +- +- +- +- +- +- Refresh rate +- +- +- +- +- +- +- +- Zoom rate +- +- +- +- +- +- +- +- Automatic +- +- +- +- +- +- +- +- 100% (recommended) +- +- +- +- +- +- +- +- 200% +- +- +- +- +- +- +- +- Apply +- +- +- +- +- +- +- +- Close +- +- +- +- +- +- Open +- +- +- +- +- +- Set as main display +- +- +- +- +- +- (recommended) +- +- +- +- +- Is the display normal? +- +- +- +- +- Save current configuration(K) +- +- +- +- +- Restore previous configuration(R) +- +- +- +- +- The display will resume the previous configuration in %1 seconds +- +- +- +- +- KiranDisplayConfigurationPanel +- +- +- +- Form +- +- +- +- +- +- Rotate left 90 degrees +- +- +- +- +- +- Rotate right 90 degrees +- +- +- +- +- +- Turn left and right +- +- +- +- +- +- upside down +- +- +- +- +- +- Identification display +- +- +- +- +- KiranModuleWidget +- +- +- +- Form +- +- +- +- +- Warning +- +- +- +- +- KiranTimeDateWidget +- +- +- +- +- KiranTimeDateWidget +- +- +- +- +- +- +- Automatic synchronizetion +- 自动同步 +- +- +- +- Change Time Zone +- 更改时区 +- +- +- +- Set Time Manually +- 手动设置时间 +- +- +- +- Time date format setting +- 日期时间格式设置 +- +- +- +- %1(%2) +- %1时间(%2) +- +- +- +- KiranTimePickerWidget +- +- +- +- +- Form +- +- +- +- +- KiranTimeZone +- +- +- +- +- Form +- +- +- +- +- Search in all time zones... +- 在所有时区中搜索... +- +- +- +- KiranTimeZoneItem +- +- +- +- +- Form +- +- +- +- +- No search results, please search again... +- 无搜索结果,请重新搜索... +- +- +- +- KiranTimeZoneList +- +- +- +- +- Form +- +- +- +- +- KiranTips +- +- +- +- +- Form +- +- +- +- +- KylinsecLogo +- +- +- Copyright © +- +- +- +- +- KylinSec. All rights reserved. +- +- +- +- +- LayoutItem +- +- +- +- Form +- +- +- +- +- LayoutList +- +- +- +- LayoutList +- +- +- +- +- LayoutPage +- +- +- +- Form +- +- +- +- +- +- Select Kayboard Layout +- +- +- +- +- +- +- Edit +- +- +- +- +- +- +- Add Layout +- +- +- +- +- +- Addition +- +- +- +- +- +- Return +- +- +- +- +- +- +- +- Failed +- +- +- +- +- You have added this keyboard layout! +- +- +- +- +- The %1 keyboard layout does not exist! +- +- +- +- +- The keyboard layout is currently in use and cannot be deleted! +- +- +- +- +- Delete Layout +- +- +- +- +- You do not appear to have added %1 keyboard layout! +- +- +- +- +- Finish +- +- +- +- +- LicenseAgreement +- +- +- +- Form +- +- +- +- +- +- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> +-<html><head><meta name="qrichtext" content="1" /><style type="text/css"> +-p, li { white-space: pre-wrap; } +-</style></head><body style=" font-family:'Noto Sans CJK SC'; font-size:9pt; font-weight:400; font-style:normal;"> +-<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><br /></p></body></html> +- +- +- +- +- +- Export +- +- +- +- +- +- Close +- +- +- +- +- Save +- +- +- +- +- PDF(*.pdf) +- +- +- +- +- Export License +- +- +- +- +- Export License failed! +- +- +- +- +- User End License Agreement +- +- +- +- +- +- +- +- None +- +- +- +- +- Version License +- +- +- +- +- ManagerTray +- +- +- Network settings +- +- +- +- +- Media Key +- +- +- Audio Play +- +- +- +- +- Search +- +- +- +- +- WWW +- +- +- +- +- Audio Lower Volume +- +- +- +- +- Audio Raise Volume +- +- +- +- +- Mic Mute +- +- +- +- +- Audio Stop +- +- +- +- +- Explorer +- +- +- +- +- Calculator +- +- +- +- +- Audio Mute +- +- +- +- +- Audio Pause +- +- +- +- +- Audio Prev +- +- +- +- +- Audio Media +- +- +- +- +- Audio Next +- +- +- +- +- Mail +- +- +- +- +- Tools +- +- +- +- +- Eject +- +- +- +- +- MonthSpinBox +- +- +- MMMM +- MMMM +- +- +- +- MousePage +- +- +- +- +- Form +- +- +- +- +- +- +- Select Mouse Hand +- +- +- +- +- +- +- Mouse Motion Acceleration +- +- +- +- +- +- +- Slow +- +- +- +- +- +- +- Fast +- +- +- +- +- +- +- Natural Scroll +- +- +- +- +- +- +- Middle Emulation Enabled +- +- +- +- +- Right Hand Mode +- +- +- +- +- Left Hand Mode +- +- +- +- +- NetworkDetails +- +- +- NetworkDetails +- +- +- +- +- Network Details +- +- +- +- +- TextLabel +- +- +- +- +- NetworkPlugin +- +- +- Wired Connection %1 +- +- +- +- +- Wireless Connection %1 +- +- +- +- +- OutputPage +- +- +- +- +- OutputPage +- +- +- +- +- +- +- Output devices +- +- +- +- +- +- +- Output volume +- +- +- +- +- +- +- Left/right balance +- +- +- +- +- +- +- Left +- +- +- +- +- +- +- Right +- +- +- +- +- No output device detected +- +- +- +- +- PanelWidget +- +- +- +- Form +- +- +- +- +- PanelWindow +- +- +- Control Panel +- +- +- +- +- PasswordExpirationPolicyPage +- +- +- +- +- PasswordExpirationPolicyPage +- +- +- +- +- +- +- User expires +- +- +- +- +- +- +- yyyy-MM-dd +- +- +- +- +- +- +- Last password change +- +- +- +- +- +- +- 1990-01-01 +- +- +- +- +- +- +- Maximum vaild days of password +- +- +- +- +- +- +- Prompt time before password expiration +- +- +- +- +- +- +- how many days after password expires will become inactive +- +- +- +- +- +- +- save +- 保存 +- +- +- +- +- +- return +- +- +- +- +- +- +- day +- +- +- +- +- Popup +- +- +- Dialog +- +- +- +- +- Ok +- +- +- +- +- TextLabel +- +- +- +- +- cancel +- +- +- +- +- PowerSettingsPage +- +- +- +- +- PowerSettingsPage +- +- +- +- +- +- +- After idle for more than the following time, the computer will execute +- +- +- +- +- +- +- The monitor will turn off when it is idle +- +- +- +- +- Suspend +- +- +- +- +- Shutdown +- +- +- +- +- Hibernate +- +- +- +- +- Do nothing +- +- +- +- +- QObject +- +- +- +- +- Failed +- +- +- +- +- Set font failed! +- +- +- +- +- Get icon themes failed! +- +- +- +- +- Get cursor themes failed! +- +- +- +- +- Warning +- +- +- +- +- There is no theme to set! +- +- +- +- +- +- +- +- Tips +- +- +- +- +- +- +- +- OK(K) +- +- +- +- +- Failed to apply display settings!%1 +- +- +- +- +- Fallback display setting failed! %1 +- +- +- +- +- No search results, please search again... +- 无搜索结果,请重新搜索... +- +- +- +- %1Day +- +- +- +- +- %1Hour +- +- +- +- +- %1Minute +- +- +- +- +- never +- +- +- +- +- SelectAvatarPage +- +- +- Confirm +- +- +- +- +- Return +- +- +- +- +- select picture +- +- +- +- +- image files(*.bmp *.jpg *.png *.tif *.gif *.pcx *.tga *.exif *.fpx *.svg *.psd *.cdr *.pcd *.dxf *.ufo *.eps *.ai *.raw *.WMF *.webp) +- +- +- +- +- SettingBriefWidget +- +- +- +- Form +- +- +- +- +- +- +- +- +- +- TextLabel +- +- +- +- +- Shortcut +- +- +- +- Form +- +- +- +- +- +- Custom +- +- +- +- +- +- +- +- Edit +- +- +- +- +- +- +- +- +- +- Add +- +- +- +- +- +- Reset +- +- +- +- +- +- Custom Shortcut Name +- +- +- +- +- +- Custom Shortcut application +- +- +- +- +- +- Custom Shortcut Key +- +- +- +- +- +- Cancel +- +- +- +- +- +- Shortcut Name +- +- +- +- +- +- Shortcut application +- +- +- +- +- +- Shortcut key +- +- +- +- +- +- Save +- +- +- +- +- +- return +- +- +- +- +- Please enter a search keyword... +- +- +- +- +- Required +- +- +- +- +- +- Please press the new shortcut key +- +- +- +- +- Finished +- +- +- +- +- +- +- +- +- +- +- Failed +- +- +- +- +- Get shortcut failed,error: +- +- +- +- +- failed to load shortcut key data! +- +- +- +- +- List shortcut failed,error:%1 +- +- +- +- +- Error +- +- +- +- +- Open File +- +- +- +- +- System +- +- +- +- +- Sound +- +- +- +- +- Delete shortcut failed,error: +- +- +- +- +- +- Warning +- +- +- +- +- +- Please complete the shortcut information! +- +- +- +- +- Set shortcut +- +- +- +- +- Are you sure you want to disable this shortcut? +- +- +- +- +- Modify system shortcut failed,error: +- +- +- +- +- Modify custom shortcut failed,error: +- +- +- +- +- Add custom shortcut failed,error: +- +- +- +- +- Reset shortcut failed,error: +- +- +- +- +- Cannot use shortcut "%1", Because you cannot enter with this key.Please try again using Ctrl, Alt, or Shift at the same time. +- +- +- +- +- Shortcut keys %1 are already used in %2,Please try again! +- +- +- +- +- ShortcutItem +- +- +- +- Form +- +- +- +- +- +- +- +- TextLabel +- +- +- +- +- StatusNotification +- +- +- Connection activated +- +- +- +- +- You are now connected to the network "%1" +- +- +- +- +- Connection deactivated +- +- +- +- +- You have now disconnected the network "%1" +- +- +- +- +- Connection Failed +- +- +- +- +- Failed to connect to the network "%1" +- +- +- +- +- SubItem1 +- +- +- Dialog +- +- +- +- +- 弹窗 +- +- +- +- +- SubItem1 +- +- +- +- +- SubItem2 +- +- +- Dialog +- +- +- +- +- SubItem2 +- +- +- +- +- SystemInformation +- +- +- +- Form +- +- +- +- +- +- Host Name: +- +- +- +- +- +- +- +- +- +- +- +- TextLabel +- +- +- +- +- +- Change +- +- +- +- +- +- System Version: +- +- +- +- +- +- Kernel Version: +- +- +- +- +- +- System Architecture: +- +- +- +- +- +- EULA: +- +- +- +- +- +- +- +- Show +- +- +- +- +- +- Version License: +- +- +- +- +- +- +- +- Unknow +- +- +- +- +- TextInputDialog +- +- +- Tips +- +- +- +- +- ThemeWidget +- +- +- Dark Theme +- +- +- +- +- Light Theme +- +- +- +- +- Themes +- +- +- +- Form +- +- +- +- +- +- Dark and Light Theme +- +- +- +- +- +- Themes Settings +- +- +- +- +- +- Open Window Effects +- +- +- +- +- Choose icon themes +- +- +- +- +- +- Unknown +- +- +- +- +- Choose cursor themes +- +- +- +- +- ThreadObject +- +- +- Failed +- +- +- +- +- List shortcut failed,error: +- +- +- +- +- TimezoneSettings +- +- +- +- +- TimezoneSettings +- +- +- +- +- +- +- Select Time Zone +- 选择时区 +- +- +- +- +- +- save +- 保存 +- +- +- +- +- +- reset +- 重置 +- +- +- +- TouchPadPage +- +- +- +- +- Form +- +- +- +- +- +- +- TouchPad Enabled +- +- +- +- +- +- +- Select TouchPad Hand +- +- +- +- +- +- +- TouchPad Motion Acceleration +- +- +- +- +- +- +- Slow +- +- +- +- +- +- +- Fast +- +- +- +- +- +- +- Select Click Method +- +- +- +- +- +- +- Select Scroll Method +- +- +- +- +- +- +- Natural Scroll +- +- +- +- +- +- +- Enabled while Typing +- +- +- +- +- +- +- Tap to Click +- +- +- +- +- Right Hand Mode +- +- +- +- +- Left Hand Mode +- +- +- +- +- Press and Tap +- +- +- +- +- Tap +- +- +- +- +- Two Finger Scroll +- +- +- +- +- Edge Scroll +- +- +- +- +- TrayItemWidget +- +- +- +- TrayItemWidget +- +- +- +- +- +- Icon +- +- +- +- +- +- Name +- +- +- +- +- +- Status +- +- +- +- +- +- Ignore +- +- +- +- +- +- Disconnect +- +- +- +- +- +- +- +- Cancel +- +- +- +- +- +- +- +- Connect +- +- +- +- +- Connected +- +- +- +- +- Unconnected +- +- +- +- +- Please input password +- +- +- +- +- Please input a network name +- +- +- +- +- TrayPage +- +- +- +- TrayPage +- +- +- +- +- +- TextLabel +- +- +- +- +- Select wired network card +- +- +- +- +- Select wireless network card +- +- +- +- +- UserInfoPage +- +- +- +- +- Form +- +- +- +- +- +- +- Account +- +- +- +- +- +- +- Change password +- +- +- +- +- +- +- User id +- +- +- +- +- +- +- User type +- +- +- +- +- +- +- User status +- +- +- +- +- +- +- auth manager +- +- +- +- +- +- +- Password expiration policy +- +- +- +- +- +- +- Confirm +- +- +- +- +- +- +- Delete +- +- +- +- +- +- +- Current password +- +- +- +- +- +- +- New password +- +- +- +- +- +- +- Enter the new password again +- +- +- +- +- +- +- Save +- +- +- +- +- +- +- Cancel +- +- +- +- +- standard +- +- +- +- +- administrator +- +- +- +- +- Please enter the new user password +- +- +- +- +- Please enter the password again +- +- +- +- +- The password you enter must be the same as the former one +- +- +- +- +- Please enter the current user password +- +- +- +- +- The current password is incorrect +- +- +- +- +- The new password cannot be the same as the current password +- +- +- +- +- +- +- +- Error +- +- +- +- +- Password encryption failed +- +- +- +- +- user information updated successfully +- +- +- +- +- Password updated successfully +- +- +- +- +- The directory and files under the user's home directory are deleted with the user.Are you sure you want to delete the user(%1)? +- +- +- +- +- Warning +- +- +- +- +- VolumeSettingPage +- +- +- +- VolumeSettingPage +- +- +- +- +- +- +- Volume +- +- +- +- +- VpnIPsec +- +- +- +- VpnIPsec +- +- +- +- +- +- Enable IPsec +- +- +- +- +- +- Group Name +- +- +- +- +- +- Group ID +- +- +- +- +- +- Pre-Shared Key +- +- +- +- +- +- Internet Key Exchange Protocol +- +- +- +- +- +- Encapsulating Security Payload +- +- +- +- +- VpnIpvx +- +- +- +- VpnIpvx +- +- +- +- +- +- IPV4 Method +- +- +- +- +- +- Only applied in corresponding resources +- +- +- +- +- +- Preferred DNS +- +- +- +- +- +- Alternate DNS +- +- +- +- +- Auto +- +- +- +- +- VpnL2tpSetting +- +- +- +- VpnL2tpSetting +- +- +- +- +- VPN name +- +- +- +- +- VpnManager +- +- +- +- VpnManager +- +- +- +- +- +- VPN type +- +- +- +- +- +- Save +- +- +- +- +- +- Return +- +- +- +- +- VPN +- +- +- +- +- L2TP +- +- +- +- +- PPTP +- +- +- +- +- Tips +- +- +- +- +- Password required to connect to %1. +- +- +- +- +- VpnPpp +- +- +- +- VpnPpp +- +- +- +- +- +- VPN PPP +- +- +- +- +- +- Use MPPE +- +- +- +- +- +- Security +- +- +- +- +- +- Stateful MPPE +- +- +- +- +- All available (default) +- +- +- +- +- 40-bit (less secure) +- +- +- +- +- 128-bit (most secure) +- +- +- +- +- Refuse EAP Authentication +- +- +- +- +- Refuse PAP Authentication +- +- +- +- +- Refuse CHAP Authentication +- +- +- +- +- Refuse MSCHAP Authentication +- +- +- +- +- Refuse MSCHAPv2 Authentication +- +- +- +- +- No BSD Data Compression +- +- +- +- +- No Deflate Data Compression +- +- +- +- +- No TCP Header Compression +- +- +- +- +- No Protocol Field Compression +- +- +- +- +- No Address/Control Compression +- +- +- +- +- Send PPP Echo Packets +- +- +- +- +- VpnPptpSetting +- +- +- +- VpnPptpSetting +- +- +- +- +- VPN name +- +- +- +- +- VpnWidget +- +- +- +- VpnWidget +- +- +- +- +- +- Gateway +- +- +- +- +- +- User Name +- +- +- +- +- +- Password Options +- +- +- +- +- +- Password +- +- +- +- +- +- PushButton +- +- +- +- +- +- NT Domain +- +- +- +- +- Saved +- +- +- +- +- Ask +- +- +- +- +- Not required +- +- +- +- +- Wallpaper +- +- +- +- Form +- +- +- +- +- +- Set wallpaper +- +- +- +- +- +- Desktop Wallpaper Preview +- +- +- +- +- +- Lock Screen WallPaper Preview +- +- +- +- +- +- Select wallpaper +- +- +- +- +- +- Select Wallpaper +- +- +- +- +- Set Desktop Wallpaper +- +- +- +- +- Set Lock Screen Wallpaper +- +- +- +- +- +- set wallpaper +- +- +- +- +- +- Set wallpaper failed! +- +- +- +- +- select picture +- +- +- +- +- image files(*.bmp *.jpg *.png *.tif *.gif *.pcx *.tga *.exif *.fpx *.svg *.psd *.cdr *.pcd *.dxf *.ufo *.eps *.ai *.raw *.WMF *.webp) +- +- +- +- +- Add Image Failed +- +- +- +- +- The image already exists! +- +- +- +- +- WiredManager +- +- +- +- WiredManager +- +- +- +- +- +- Save +- +- +- +- +- +- Return +- +- +- +- +- Wired Network Adapter +- +- +- +- +- WiredSettingPage +- +- +- +- WiredSettingPage +- +- +- +- +- Network name +- +- +- +- +- WirelessManager +- +- +- +- WirelessManager +- +- +- +- +- +- Save +- +- +- +- +- +- Return +- +- +- +- +- Wireless Network Adapter +- +- +- +- +- Tips +- +- +- +- +- Password required to connect to %1. +- +- +- +- +- WirelessSecurityWidget +- +- +- +- WirelessSecurityWidget +- +- +- +- +- +- Security +- +- +- +- +- +- Password Options +- +- +- +- +- +- Password +- +- +- +- +- +- PushButton +- +- +- +- +- None +- +- +- +- +- WPA/WPA2 Personal +- +- +- +- +- Save password for all users +- +- +- +- +- Save password for this user +- +- +- +- +- Ask me always +- +- +- +- +- WirelessSettingPage +- +- +- +- WirelessSettingPage +- +- +- +- +- Wireless name +- +- +- +- +- WirelessWidget +- +- +- +- WirelessWidget +- +- +- +- +- +- SSID +- +- +- +- +- +- MAC Address Of Device +- +- +- +- +- +- Custom MTU +- +- +- +- +- No device specified +- +- +- + + YearSpinBox + +diff --git a/src/main.cpp b/src/main.cpp +index 6247adc..55cafc5 100644 +--- a/src/main.cpp ++++ b/src/main.cpp +@@ -31,8 +31,8 @@ using namespace std; + + bool installTranslator() + { +- QTranslator tsor; +- if (!tsor.load(QLocale(), ++ QTranslator* tsor = new QTranslator(qApp); ++ if (!tsor->load(QLocale(), + qAppName(), + ".", + TRANSLATE_PREFIX, +@@ -42,7 +42,7 @@ bool installTranslator() + return false; + } + +- QCoreApplication::installTranslator(&tsor); ++ QCoreApplication::installTranslator(tsor); + return true; + } + +diff --git a/translations/kiran-control-panel.zh_CN.ts b/translations/kiran-control-panel.zh_CN.ts +index 6694f07..4da29a1 100644 +--- a/translations/kiran-control-panel.zh_CN.ts ++++ b/translations/kiran-control-panel.zh_CN.ts +@@ -1,176 +1,33 @@ + + + +- +- Dialog001 +- +- +- Dialog +- +- +- +- +- 弹窗 +- +- +- +- +- Dialog001 +- +- +- +- +- Dialog002 +- +- +- Dialog +- +- +- +- +- Dialog002 +- +- +- +- +- KiranControlCenter +- +- +- +- +- Form +- +- +- +- +- KiranControlCenterWindow +- +- +- Control Center +- 控制中心 +- +- +- +- KiranControlPanelWindow +- +- Control Center +- 控制中心 +- +- +- +- KiranModuleClassWidget +- +- +- +- +- Form +- +- +- + + KiranModuleWidget + +- ++ + Warning + 警告 + + +- +- OK(K) +- 确定(K) +- +- +- +- Cancel(R) +- 取消(R) +- +- +- +- The edited content in %1 is not saved. After switching, the edited content will be lost. Are you sure you want to switch? +- %1 中编辑内容未保存,切换后编辑内容将丢失, 确定要切换吗? +- +- +- +- +- +- Form +- +- +- +- +- KiranSearchLineEdit +- +- +- search... +- 搜索... +- +- +- +- PluginDemoWindow +- +- +- PluginDemo +- ++ ++ The edited content in %1 is not saved. After switching, the edited content will be lost. Are you sure you want to save? ++ %1中编辑的内容未保存,切换后编辑的内容将会丢失。您确定要保存吗? + + + +- Popup +- +- +- Dialog +- +- +- +- +- Ok +- +- ++ PanelWidget + +- +- TextLabel +- +- +- +- +- cancel ++ ++ Form + + + + +- QObject +- +- +- Tips +- 提示 +- +- +- +- OK(K) +- 确定(K) +- ++ PanelWindow + +- +- Failed to load plug-in %1。%2 +- 加载插件%1失败。%2 +- +- +- +- main +- +- +- kiran control panel module runalone +- +- +- +- +- +- Module name. +- +- +- +- +- Print plugins dir +- ++ ++ Control Panel ++ 控制面板 + + + +-- +2.33.0 + diff --git a/kiran-control-panel.spec b/kiran-control-panel.spec index d00224f..a115852 100644 --- a/kiran-control-panel.spec +++ b/kiran-control-panel.spec @@ -1,6 +1,6 @@ Name: kiran-control-panel Version: 2.3.1 -Release: 3 +Release: 4 Summary: Kiran Control Panel Summary(zh_CN): Kiran桌面控制面板 @@ -9,6 +9,7 @@ Source0: %{name}-%{version}.tar.gz Patch0001: 0001-feature-audio-fix-unplugging-headphones-causes-crash.patch Patch0002: 0001-build-system-add-system-plugin-build-library-printsu.patch +Patch0003: 0001-fix-translator-update-translator.patch BuildRequires: gcc-c++ BuildRequires: cmake >= 3.2 @@ -130,7 +131,6 @@ make %{?_smp_mflags} #network %{_sysconfdir}/xdg/autostart/kiran-network-status-icon.desktop %{_bindir}/kiran-network-status-icon -%{_datadir}/kiran-control-panel/translations/* #display %{_datadir}/kiran-cpanel-display/translations/* @@ -144,9 +144,20 @@ make %{?_smp_mflags} #system %{_datadir}/kiran-cpanel-system/translations/* +#appearance +%{_datadir}/kiran-cpanel-appearance/translations/* + +#keybinding +%{_datadir}/kiran-cpanel-keybinding/translations/* + +#keyboard +%{_datadir}/kiran-cpanel-keyboard/translations/* + +#timedate +%{_datadir}/kiran-cpanel-timedate/translations/* + %files -n kiran-cpanel-launcher %{_bindir}/kiran-cpanel-launcher -%{_datadir}/kiran-control-panel/translations/kiran-cpanel-launcher* %files devel %dir %{_includedir}/kiran-control-panel @@ -157,6 +168,9 @@ make %{?_smp_mflags} rm -rf %{buildroot} %changelog +* Tue Jul 12 2022 liuxinhao - 2.3.1-4 +- KYOS-B: fix kiran control panel translator + * Mon Jul 11 2022 liuxinhao - 2.3.1-3 - KYOS-B: fix system infomation plugin build require