+
+ //Check for expiration
+ if(x264_version_date().addMonths(6) < QDate::currentDate())
+ {
+ QMessageBox msgBox(this);
+ msgBox.setIcon(QMessageBox::Information);
+ msgBox.setWindowTitle(tr("Update Notification"));
+ msgBox.setWindowFlags(Qt::Window | Qt::WindowTitleHint | Qt::CustomizeWindowHint);
+ msgBox.setText(tr("<nobr><tt>Oups, this version of 'Simple x264 Launcher' is more than 6 months old.<br><br>Please check the official web-site at <a href=\"%1\">%1</a> for updates!<br></tt></nobr>").replace("-", "−").arg(home_url));
+ QPushButton *btn1 = msgBox.addButton(tr("Discard"), QMessageBox::NoRole);
+ QPushButton *btn2 = msgBox.addButton(tr("Discard"), QMessageBox::AcceptRole);
+ btn1->setEnabled(false);
+ btn2->setVisible(false);
+ QTimer::singleShot(5000, btn1, SLOT(hide()));
+ QTimer::singleShot(5000, btn2, SLOT(show()));
+ msgBox.exec();
+ }