This commit is contained in:
朱子楚\zhuzi
2024-03-09 19:46:02 +08:00
parent a43637f75e
commit eff9e385f5
2 changed files with 28 additions and 25 deletions

View File

@ -19,9 +19,6 @@ void TranslateHelper::init(QQmlEngine* engine){
_translator = new QTranslator(this);
qApp->installTranslator(_translator);
QString translatorPath = QGuiApplication::applicationDirPath()+"/i18n";
#ifdef Q_OS_MACX
translatorPath.append("/../Resources/");
#endif
_translator->load(QString::fromStdString("%1/example_%2.qm").arg(translatorPath,_current));
_engine->retranslate();
}