Commit 494b5957 authored by David Faure's avatar David Faure
Browse files

GIT_SILENT ensure non-null windowHandle

parent 2669dbbe
......@@ -57,6 +57,7 @@ void MigrationAgent::configure(WId windowId)
dlg->resize(600, 300);
if (windowId) {
dlg->setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(dlg->windowHandle(), windowId);
}
dlg->show();
......
......@@ -193,6 +193,7 @@ void DavGroupwareResource::configure(WId windowId)
SetupWizard wizard;
if (windowId) {
wizard.setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(wizard.windowHandle(), windowId);
}
......@@ -226,6 +227,7 @@ void DavGroupwareResource::configure(WId windowId)
ConfigDialog dialog;
if (windowId) {
dialog.setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(dialog.windowHandle(), windowId);
}
......
......@@ -67,6 +67,7 @@ EwsConfigDialog::EwsConfigDialog(EwsResource *parentResource, EwsClient &client,
, mSettings(settings)
{
if (wId) {
setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(windowHandle(), wId);
}
......
......@@ -40,6 +40,7 @@ EwsMtaConfigDialog::EwsMtaConfigDialog(EwsMtaResource *parentResource, WId wId)
, mParentResource(parentResource)
{
if (wId) {
setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(windowHandle(), wId);
}
......
......@@ -47,6 +47,7 @@ GoogleSettingsDialog::GoogleSettingsDialog(GoogleAccountManager *accountManager,
, m_parentResource(parent)
, m_accountManager(accountManager)
{
setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(windowHandle(), wId);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel, this);
QVBoxLayout *topLayout = new QVBoxLayout(this);
......
......@@ -72,6 +72,7 @@ QByteArray ImapResource::clientId() const
QDialog *ImapResource::createConfigureDialog(WId windowId)
{
SetupServer *dlg = new SetupServer(this, windowId);
dlg->setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(dlg->windowHandle(), windowId);
dlg->setWindowTitle(i18n("IMAP Account Settings"));
dlg->setWindowIcon(QIcon::fromTheme(QStringLiteral("network-server")));
......
......@@ -264,6 +264,7 @@ int ImapResourceBase::configureSubscription(qlonglong windowId)
mSubscriptions = new SubscriptionDialog(nullptr, SubscriptionDialog::AllowToEnableSubscription);
if (windowId) {
mSubscriptions->setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(mSubscriptions->windowHandle(), windowId);
}
mSubscriptions->setWindowTitle(i18nc("@title:window", "Serverside Subscription"));
......
......@@ -83,6 +83,7 @@ void SettingsPasswordRequester::askUserInput(const QString &serverError)
connect(dialog, &QDialog::destroyed, this, &SettingsPasswordRequester::onDialogDestroyed);
m_requestDialog = dialog;
dialog->setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(dialog->windowHandle(), m_resource->winIdForDialogs());
bool checkboxResult = false;
KMessageBox::createKMessageBox(dialog, buttonBox, QMessageBox::Information,
......
......@@ -54,6 +54,7 @@ SettingsDialog::SettingsDialog(WId windowId, Settings *settings)
setWindowTitle(i18nc("@title", "Configure Calendar"));
if (windowId) {
setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(windowHandle(), windowId);
}
......
......@@ -95,6 +95,7 @@ QByteArray KolabResource::clientId() const
QDialog *KolabResource::createConfigureDialog(WId windowId)
{
SetupServer *dlg = new SetupServer(this, windowId);
dlg->setAttribute(Qt::WA_NativeWindow, true);
KWindowSystem::setMainWindow(dlg->windowHandle(), windowId);
dlg->setWindowTitle(i18n("Kolab Account Settings"));
dlg->setWindowIcon(QIcon::fromTheme(QStringLiteral("kolab")));
......
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