mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 17:35:34 +08:00
Avoid crash when accessing the main windget position
This commit is contained in:
@@ -659,7 +659,7 @@ namespace BlackGui
|
||||
QPoint pos = CGuiUtility::mainWidgetGlobalPosition();
|
||||
if (pos.isNull())
|
||||
{
|
||||
pos = sGui->currentScreen()->geometry().center() - this->rect().center();
|
||||
pos = CGuiApplication::currentScreen()->geometry().center() - this->rect().center();
|
||||
}
|
||||
|
||||
const int x = pos.x() + m_offsetWhenFloating.x();
|
||||
|
||||
Reference in New Issue
Block a user