添加翻译(终于)

This commit is contained in:
RigoLigoRLC
2022-02-20 20:44:53 +08:00
parent 393b3f73d5
commit b0a2d64b71
3 changed files with 1059 additions and 2 deletions

View File

@@ -1,5 +1,6 @@
#include <QApplication>
#include <QPushButton>
#include <QTranslator>
#include <spklogging.h>
#include "spkui_general.h"
#include "spkstore.h"
@@ -16,6 +17,17 @@ int main(int argc, char *argv[])
QString LogPath = "";
QTranslator tr;
QLocale loc;
QString trDir;
#ifndef NDEBUG
trDir = ".";
#else // Translation files (zh.qm etc) installed to this path!
trDir = "/usr/share/spark-store/translations/";
#endif
if(tr.load(loc, "", "", "."))
a.installTranslator(&tr);
SpkStore store(false, LogPath);
// SpkDownloadMgr dl;