mirror of
https://github.com/edisionnano/QDiskInfo.git
synced 2026-04-16 04:51:29 +03:00
Fix Ubuntu PKEXEC issue, enable spanish translation (not available yet)
This commit is contained in:
@@ -117,8 +117,8 @@ void MainWindow::onPrevButtonClicked()
|
|||||||
|
|
||||||
void MainWindow::updateNavigationButtons(int currentIndex)
|
void MainWindow::updateNavigationButtons(int currentIndex)
|
||||||
{
|
{
|
||||||
prevButton->setEnabled(currentIndex > 0||(ui->actionCyclic_Navigation->isChecked() && buttonGroup->buttons().size() > 1)); // We can use setVisible if we want to mimic CrystalDiskInfo
|
prevButton->setEnabled(currentIndex > 0 || (ui->actionCyclic_Navigation->isChecked() && buttonGroup->buttons().size() > 1)); // We can use setVisible if we want to mimic CrystalDiskInfo
|
||||||
nextButton->setEnabled(currentIndex < buttonGroup->buttons().size() - 1||ui->actionCyclic_Navigation->isChecked());
|
nextButton->setEnabled(currentIndex < buttonGroup->buttons().size() - 1 || ui->actionCyclic_Navigation->isChecked());
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::updateUI()
|
void MainWindow::updateUI()
|
||||||
|
|||||||
@@ -4,5 +4,6 @@
|
|||||||
</qresource>
|
</qresource>
|
||||||
<qresource prefix="/">
|
<qresource prefix="/">
|
||||||
<file alias="translations/kdiskinfo_el_GR.qm">../translations/kdiskinfo_el_GR.qm</file>
|
<file alias="translations/kdiskinfo_el_GR.qm">../translations/kdiskinfo_el_GR.qm</file>
|
||||||
|
<file alias="translations/kdiskinfo_es_ES.qm">../translations/kdiskinfo_es_ES.qm</file>
|
||||||
</qresource>
|
</qresource>
|
||||||
</RCC>
|
</RCC>
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ QString utils::getSmartctlOutput(const QStringList &arguments, bool root, bool i
|
|||||||
process.waitForFinished(-1);
|
process.waitForFinished(-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (process.exitCode() == 127) {
|
if (process.exitCode() == 126 || process.exitCode() == 127) {
|
||||||
QMessageBox::critical(nullptr, QObject::tr("KDiskInfo Error"), QObject::tr("KDiskInfo needs root access in order to read S.M.A.R.T. data!"));
|
QMessageBox::critical(nullptr, QObject::tr("KDiskInfo Error"), QObject::tr("KDiskInfo needs root access in order to read S.M.A.R.T. data!"));
|
||||||
if (initializing) {
|
if (initializing) {
|
||||||
QTimer::singleShot(0, qApp, &QApplication::quit);
|
QTimer::singleShot(0, qApp, &QApplication::quit);
|
||||||
@@ -136,7 +136,7 @@ void utils::cancelSelfTest(const QString &deviceNode)
|
|||||||
process.start("pkexec", arguments);
|
process.start("pkexec", arguments);
|
||||||
process.waitForFinished(-1);
|
process.waitForFinished(-1);
|
||||||
|
|
||||||
if (process.exitCode() == 127) {
|
if (process.exitCode() == 126 || process.exitCode() == 127) {
|
||||||
QMessageBox::critical(nullptr, QObject::tr("KDiskInfo Error"), QObject::tr("KDiskInfo needs root access in order to abort a self-test!"));
|
QMessageBox::critical(nullptr, QObject::tr("KDiskInfo Error"), QObject::tr("KDiskInfo needs root access in order to abort a self-test!"));
|
||||||
} else if (process.exitCode() == QProcess::NormalExit) {
|
} else if (process.exitCode() == QProcess::NormalExit) {
|
||||||
QMessageBox::information(nullptr, QObject::tr("Test Requested"), QObject::tr("The self-test has been aborted"));
|
QMessageBox::information(nullptr, QObject::tr("Test Requested"), QObject::tr("The self-test has been aborted"));
|
||||||
|
|||||||
BIN
translations/kdiskinfo_es_ES.qm
Normal file
BIN
translations/kdiskinfo_es_ES.qm
Normal file
Binary file not shown.
Reference in New Issue
Block a user