mirror of
https://github.com/KDE/latte-dock.git
synced 2025-01-23 10:03:43 +03:00
x11:center applet config window on screen
This commit is contained in:
parent
6187f4d997
commit
0657ca1e4e
@ -591,6 +591,14 @@ void View::showConfigurationInterface(Plasma::Applet *applet)
|
||||
} else {
|
||||
m_appletConfigView = new PlasmaQuick::ConfigView(applet);
|
||||
m_appletConfigView.data()->init();
|
||||
|
||||
//! center applet config window
|
||||
m_appletConfigView->setScreen(screen());
|
||||
QRect scrgeometry = screenGeometry();
|
||||
QPoint position{scrgeometry.center().x() - m_appletConfigView->width() / 2, scrgeometry.center().y() - m_appletConfigView->height() / 2 };
|
||||
//!under wayland probably needs another workaround
|
||||
m_appletConfigView->setPosition(position);
|
||||
|
||||
m_appletConfigView->show();
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user