fix Error message is different from the actual requirement in plymouth

This commit is contained in:
like 2024-06-11 17:27:17 +08:00
parent 1d92a54f69
commit 6bfb280c16
5 changed files with 44 additions and 46 deletions

View File

@ -154,7 +154,7 @@ bool FileCheck::isLegalMP4File(const QString &filePath)
qint64 maxSize = 1024 * 1024 *10;
if (fileSize > maxSize) {
QMessageBox::information(nullptr, tr("error"), tr("The file size cannot exceed 1MB"));
QMessageBox::information(nullptr, tr("error"), tr("The file size cannot exceed 10MB"));
return false;
}

View File

@ -224,13 +224,13 @@ void PlymouthThemeWidget::initEditWidget()
});
QLabel *tipLabel = new QLabel();
tipLabel->setText("<html>*视频为 MP4 格式<br>*大小不超过 1 MB</html>");
tipLabel->setText("<html>*视频为 MP4 格式<br>*大小不超过 10 MB</html>");
connect(btngroup, QOverload<QAbstractButton*>::of(&QButtonGroup::buttonClicked), [=](QAbstractButton* button) {
if (button == pic) {
tipLabel->setText("<html>*尺寸为 400*400 的 PNG 图片<br>*大小不超过 20 KB</html>");
a->setType("pic");
} else {
tipLabel->setText("<html>*视频为 MP4 格式<br>*大小不超过 1 MB</html>");
tipLabel->setText("<html>*视频为 MP4 格式<br>*大小不超过 10 MB</html>");
a->setType("video");
}
});

View File

@ -132,6 +132,7 @@
<message>
<location filename="../src/fileProcess/filecheck.cpp" line="108"/>
<location filename="../src/fileProcess/filecheck.cpp" line="136"/>
<location filename="../src/fileProcess/filecheck.cpp" line="157"/>
<source>The file size cannot exceed 10MB</source>
<translation type="unfinished"></translation>
</message>
@ -162,11 +163,6 @@
<source>The file is not a mp4</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/fileProcess/filecheck.cpp" line="157"/>
<source>The file size cannot exceed 1MB</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/fileProcess/filecheck.cpp" line="177"/>
<source>The file size cannot exceed 20KB</source>
@ -763,14 +759,14 @@
<message>
<location filename="../src/module/infocreatewidget.cpp" line="91"/>
<location filename="../src/module/infocreatewidget.cpp" line="94"/>
<location filename="../src/module/infocreatewidget.cpp" line="749"/>
<location filename="../src/module/infocreatewidget.cpp" line="756"/>
<source>ThemeName-CN</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="92"/>
<location filename="../src/module/infocreatewidget.cpp" line="96"/>
<location filename="../src/module/infocreatewidget.cpp" line="750"/>
<location filename="../src/module/infocreatewidget.cpp" line="757"/>
<source>ThemeName-EN</source>
<translation type="unfinished"></translation>
</message>
@ -801,54 +797,55 @@
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="192"/>
<location filename="../src/module/infocreatewidget.cpp" line="222"/>
<location filename="../src/module/infocreatewidget.cpp" line="298"/>
<location filename="../src/module/infocreatewidget.cpp" line="229"/>
<location filename="../src/module/infocreatewidget.cpp" line="305"/>
<source>Please enter less than 15 characters</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="201"/>
<location filename="../src/module/infocreatewidget.cpp" line="270"/>
<location filename="../src/module/infocreatewidget.cpp" line="318"/>
<location filename="../src/module/infocreatewidget.cpp" line="374"/>
<location filename="../src/module/infocreatewidget.cpp" line="207"/>
<location filename="../src/module/infocreatewidget.cpp" line="277"/>
<location filename="../src/module/infocreatewidget.cpp" line="325"/>
<location filename="../src/module/infocreatewidget.cpp" line="381"/>
<source>Input format error!</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="207"/>
<location filename="../src/module/infocreatewidget.cpp" line="280"/>
<location filename="../src/module/infocreatewidget.cpp" line="327"/>
<location filename="../src/module/infocreatewidget.cpp" line="383"/>
<location filename="../src/module/infocreatewidget.cpp" line="202"/>
<location filename="../src/module/infocreatewidget.cpp" line="214"/>
<location filename="../src/module/infocreatewidget.cpp" line="287"/>
<location filename="../src/module/infocreatewidget.cpp" line="334"/>
<location filename="../src/module/infocreatewidget.cpp" line="390"/>
<source>Input is empty!</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="230"/>
<location filename="../src/module/infocreatewidget.cpp" line="237"/>
<source>Please enter more than 1 characters</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="239"/>
<location filename="../src/module/infocreatewidget.cpp" line="246"/>
<source>Please don&apos;t duplicate the name of a package that already exists!</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="262"/>
<location filename="../src/module/infocreatewidget.cpp" line="269"/>
<source>Please keep theme names in lowercase!</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="354"/>
<location filename="../src/module/infocreatewidget.cpp" line="361"/>
<source>Please enter more than 6 characters</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="428"/>
<location filename="../src/module/infocreatewidget.cpp" line="435"/>
<source>Set as a theme for system use during installation</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="346"/>
<location filename="../src/module/infocreatewidget.cpp" line="353"/>
<source>Please enter less than 35 characters</source>
<translation type="unfinished"></translation>
</message>

Binary file not shown.

View File

@ -132,6 +132,7 @@
<message>
<location filename="../src/fileProcess/filecheck.cpp" line="108"/>
<location filename="../src/fileProcess/filecheck.cpp" line="136"/>
<location filename="../src/fileProcess/filecheck.cpp" line="157"/>
<source>The file size cannot exceed 10MB</source>
<translation>10MB</translation>
</message>
@ -163,9 +164,8 @@
<translation>mp4格式</translation>
</message>
<message>
<location filename="../src/fileProcess/filecheck.cpp" line="157"/>
<source>The file size cannot exceed 1MB</source>
<translation>1MB</translation>
<translation type="vanished">1MB</translation>
</message>
<message>
<location filename="../src/fileProcess/filecheck.cpp" line="177"/>
@ -787,14 +787,14 @@
<message>
<location filename="../src/module/infocreatewidget.cpp" line="91"/>
<location filename="../src/module/infocreatewidget.cpp" line="94"/>
<location filename="../src/module/infocreatewidget.cpp" line="749"/>
<location filename="../src/module/infocreatewidget.cpp" line="756"/>
<source>ThemeName-CN</source>
<translation>-</translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="92"/>
<location filename="../src/module/infocreatewidget.cpp" line="96"/>
<location filename="../src/module/infocreatewidget.cpp" line="750"/>
<location filename="../src/module/infocreatewidget.cpp" line="757"/>
<source>ThemeName-EN</source>
<translation>-</translation>
</message>
@ -825,49 +825,50 @@
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="192"/>
<location filename="../src/module/infocreatewidget.cpp" line="222"/>
<location filename="../src/module/infocreatewidget.cpp" line="298"/>
<location filename="../src/module/infocreatewidget.cpp" line="229"/>
<location filename="../src/module/infocreatewidget.cpp" line="305"/>
<source>Please enter less than 15 characters</source>
<translation>15</translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="201"/>
<location filename="../src/module/infocreatewidget.cpp" line="270"/>
<location filename="../src/module/infocreatewidget.cpp" line="318"/>
<location filename="../src/module/infocreatewidget.cpp" line="374"/>
<location filename="../src/module/infocreatewidget.cpp" line="207"/>
<location filename="../src/module/infocreatewidget.cpp" line="277"/>
<location filename="../src/module/infocreatewidget.cpp" line="325"/>
<location filename="../src/module/infocreatewidget.cpp" line="381"/>
<source>Input format error!</source>
<translation></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="207"/>
<location filename="../src/module/infocreatewidget.cpp" line="280"/>
<location filename="../src/module/infocreatewidget.cpp" line="327"/>
<location filename="../src/module/infocreatewidget.cpp" line="383"/>
<location filename="../src/module/infocreatewidget.cpp" line="202"/>
<location filename="../src/module/infocreatewidget.cpp" line="214"/>
<location filename="../src/module/infocreatewidget.cpp" line="287"/>
<location filename="../src/module/infocreatewidget.cpp" line="334"/>
<location filename="../src/module/infocreatewidget.cpp" line="390"/>
<source>Input is empty!</source>
<translation></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="230"/>
<location filename="../src/module/infocreatewidget.cpp" line="237"/>
<source>Please enter more than 1 characters</source>
<translation>1</translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="239"/>
<location filename="../src/module/infocreatewidget.cpp" line="246"/>
<source>Please don&apos;t duplicate the name of a package that already exists!</source>
<translation></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="262"/>
<location filename="../src/module/infocreatewidget.cpp" line="269"/>
<source>Please keep theme names in lowercase!</source>
<translation></translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="354"/>
<location filename="../src/module/infocreatewidget.cpp" line="361"/>
<source>Please enter more than 6 characters</source>
<translation>6</translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="428"/>
<location filename="../src/module/infocreatewidget.cpp" line="435"/>
<source>Set as a theme for system use during installation</source>
<translation>使</translation>
</message>
@ -880,7 +881,7 @@
<translation type="vanished">themename </translation>
</message>
<message>
<location filename="../src/module/infocreatewidget.cpp" line="346"/>
<location filename="../src/module/infocreatewidget.cpp" line="353"/>
<source>Please enter less than 35 characters</source>
<translation>35</translation>
</message>