fix Warning
This commit is contained in:
1 parent
593c221d23
commit
8345470273
316 files changed
+1246
-929
No files matched your search
@@ -24,9 +24,9 @@ LicenceEdit::LicenceEdit(QWidget *parent)
|
||||
this, &LicenceEdit::onOk);
|
||||
connect(m_ui->nglDialogButtonBox, &NGLDialogButtonBox::onCancel,
|
||||
this, &LicenceEdit::onCancel);
|
||||
connect(m_ui->chbIgnoreCount, &QCheckBox::stateChanged,
|
||||
connect(m_ui->chbIgnoreCount, &QCheckBox::checkStateChanged,
|
||||
this, &LicenceEdit::enableIgnoreCount);
|
||||
connect(m_ui->chbIgnoreExpiration, &QCheckBox::stateChanged,
|
||||
connect(m_ui->chbIgnoreExpiration, &QCheckBox::checkStateChanged,
|
||||
this, &LicenceEdit::enableIgnoreExpiration);
|
||||
connect(m_ui->leName, &QLineEdit::textChanged,
|
||||
this, &LicenceEdit::onNameChanged);
|
||||
@@ -47,7 +47,7 @@ LicenceEdit::~LicenceEdit()
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
void LicenceEdit::enableIgnoreCount(int checkState)
|
||||
void LicenceEdit::enableIgnoreCount(Qt::CheckState checkState)
|
||||
{
|
||||
m_ui->lbxCount->setEnabled(checkState == Qt::Unchecked);
|
||||
m_ui->sbMaxCount->setEnabled(checkState == Qt::Unchecked);
|
||||
@@ -63,7 +63,7 @@ void LicenceEdit::enableIgnoreCount(int checkState)
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
void LicenceEdit::enableIgnoreExpiration(int checkState)
|
||||
void LicenceEdit::enableIgnoreExpiration(Qt::CheckState checkState)
|
||||
{
|
||||
m_ui->lbxExpiry->setEnabled(checkState == Qt::Unchecked);
|
||||
m_ui->dateEdit->setEnabled(checkState == Qt::Unchecked);
|
||||
|
||||
@@ -38,8 +38,8 @@ private slots:
|
||||
void onOk();
|
||||
void onCancel();
|
||||
|
||||
void enableIgnoreCount(int checkState);
|
||||
void enableIgnoreExpiration(int checkState);
|
||||
void enableIgnoreCount(Qt::CheckState checkState);
|
||||
void enableIgnoreExpiration(Qt::CheckState checkState);
|
||||
void onNameChanged(const QString &name);
|
||||
private:
|
||||
Ui::LicenceEdit *m_ui;
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
*/
|
||||
|
||||
#include "mainwindow.h"
|
||||
#include <utility>
|
||||
#include "ui_mainwindow.h"
|
||||
#include "sortfilter.h"
|
||||
#include <QCloseEvent>
|
||||
@@ -250,7 +251,7 @@ void MainWindow::onActionOpen()
|
||||
m_cryptState = CryptState::Encrypted;
|
||||
}
|
||||
|
||||
for (const LtsLicence::Licence &lic : qAsConst(licVec))
|
||||
for (const LtsLicence::Licence &lic : std::as_const(licVec))
|
||||
{
|
||||
m_licences.insert(lic.name, lic);
|
||||
insertRow(lic, m_licencesModel->rowCount());
|
||||
@@ -330,7 +331,7 @@ void MainWindow::onActionSave()
|
||||
|
||||
QVector<LtsLicence::Licence> licVec;
|
||||
licVec.reserve(m_licences.size());
|
||||
for (const LtsLicence::Licence &lic : qAsConst(m_licences))
|
||||
for (const LtsLicence::Licence &lic : std::as_const(m_licences))
|
||||
licVec += lic;
|
||||
QByteArray licenceBa = LtsLicence::writeUnencryptedLicences(licVec);
|
||||
|
||||
|
||||
Reference in new issue
Block a user