translation improvement

This commit is contained in:
xueyan hu
2021-12-28 18:23:02 +08:00
parent f43fd26411
commit 656f46c17e
32 changed files with 1620 additions and 914 deletions

View File

@@ -15,7 +15,7 @@
#include <QPushButton>
#include "SelectDialog.h"
#include "mainwindow.h"
#include "event/EventCenter.h"
QString fileNameToDate(QString fileName)
{
return fileName.split("log/")[1].replace("-op.log", "");
@@ -29,7 +29,8 @@ UserOperationLogForm::UserOperationLogForm(QWidget* parent) {
layout = new QVBoxLayout(this);
QWidget* header = new QWidget(this);
QHBoxLayout* headerLayout = new QHBoxLayout(header);
headerLayout->addWidget(new QLabel(tr("Log Date:")));
QLabel* logdate = new QLabel(tr("Log Date:"));
headerLayout->addWidget(logdate);
btn = new QPushButton(header);
headerLayout->addWidget(btn, 0, Qt::AlignLeft);
headerLayout->addSpacerItem(new QSpacerItem(20, 20, QSizePolicy::Expanding));
@@ -60,6 +61,10 @@ UserOperationLogForm::UserOperationLogForm(QWidget* parent) {
}
});
connect(EventCenter::Default(), &EventCenter::ReloadLanguage, [=]() {
logdate->setText(tr("Log Date:"));
});
}
UserOperationLogForm::~UserOperationLogForm() {