Commit 97c08a56 authored by Christoffer Ackelman's avatar Christoffer Ackelman

QT: Fixed so the warranty is only displayed once.

parent 0d43a494
......@@ -389,6 +389,10 @@ CoWowWarrantQt::CoWowWarrantQt(CoWowQtObject* parent)
void CoWowQtObject::DisplayWarranty()
{
// Display only once
if (wow->HideWarranty()) {
return;
}
new CoWowWarrantQt(this);
}
......@@ -917,7 +921,7 @@ void CoWowQt::update_title(QWidget* w, int editmode)
CoWowQt::CoWowQt(QWidget* parent)
{
object = new CoWowQtObject(parent);
object = new CoWowQtObject(parent, this);
m_wait_timerid = new QTimer(object);
}
......
......@@ -234,8 +234,9 @@ class CoWowQtObject : public QObject {
Q_OBJECT
public:
CoWowQtObject(QWidget* parent) : QObject(), parent_wid(parent) {}
CoWowQtObject(QWidget* parent, CoWowQt* w) : QObject(), parent_wid(parent), wow(w) {}
QWidget* parent_wid;
CoWowQt* wow;
public slots:
void DisplayWarranty();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment