Qt: Fix a deprecated warning
warning: 'parentWidget' is deprecated: Use parent() with qobject_cast() instead [-Wdeprecated-declarations]
This commit is contained in:
parent
f4965d5dec
commit
16afad10fb
|
@ -118,7 +118,7 @@ public:
|
||||||
}
|
}
|
||||||
|
|
||||||
void showUatDialog() {
|
void showUatDialog() {
|
||||||
UatDialog *uat_dlg = new UatDialog(parentWidget(), prefs_get_uat_value(pref_));
|
UatDialog *uat_dlg = new UatDialog(qobject_cast<QWidget*>(parent()), prefs_get_uat_value(pref_));
|
||||||
connect(uat_dlg, SIGNAL(destroyed(QObject*)), mainApp, SLOT(flushAppSignals()));
|
connect(uat_dlg, SIGNAL(destroyed(QObject*)), mainApp, SLOT(flushAppSignals()));
|
||||||
uat_dlg->setWindowModality(Qt::ApplicationModal);
|
uat_dlg->setWindowModality(Qt::ApplicationModal);
|
||||||
uat_dlg->setAttribute(Qt::WA_DeleteOnClose);
|
uat_dlg->setAttribute(Qt::WA_DeleteOnClose);
|
||||||
|
|
Loading…
Reference in New Issue