mirror of
https://github.com/jankae/LibreVNA.git
synced 2026-04-04 22:17:31 +00:00
Bugfixes automatic source/receiver calibration
This commit is contained in:
parent
5b771e2a86
commit
c00d00cac2
11 changed files with 168 additions and 79 deletions
|
|
@ -3,14 +3,19 @@
|
|||
#include <QSettings>
|
||||
#include <QDebug>
|
||||
|
||||
void InformationBox::ShowMessage(QString title, QString message, QWidget *parent)
|
||||
void InformationBox::ShowMessage(QString title, QString message, QString messageID)
|
||||
{
|
||||
// check if the user still wants to see this message
|
||||
auto hash = qHash(message);
|
||||
unsigned int hash;
|
||||
if(messageID.isEmpty()) {
|
||||
hash = qHash(message);
|
||||
} else {
|
||||
hash = qHash(messageID);
|
||||
}
|
||||
|
||||
QSettings s;
|
||||
if(!s.contains(hashToSettingsKey(hash))) {
|
||||
auto box = new InformationBox(title, message, hash, parent);
|
||||
auto box = new InformationBox(title, message, hash, nullptr);
|
||||
box->exec();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ class InformationBox : public QMessageBox
|
|||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
static void ShowMessage(QString title, QString message, QWidget *parent = nullptr);
|
||||
static void ShowMessage(QString title, QString message, QString messageID = QString());
|
||||
private:
|
||||
InformationBox(QString title, QString message, unsigned int hash, QWidget *parent);
|
||||
~InformationBox();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue