mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Let Wayland to use QGuiApplication::screenAt
Looks like it works correctly nowadays
This commit is contained in:
parent
8534d6d7d7
commit
001b055ee8
3 changed files with 5 additions and 9 deletions
|
@ -794,11 +794,9 @@ void OverlayWidget::moveToScreen(bool inMove) {
|
||||||
if (!widget) {
|
if (!widget) {
|
||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
if (!Platform::IsWayland()) {
|
if (const auto screen = QGuiApplication::screenAt(
|
||||||
if (const auto screen = QGuiApplication::screenAt(
|
|
||||||
widget->geometry().center())) {
|
widget->geometry().center())) {
|
||||||
return screen;
|
return screen;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return widget->screen();
|
return widget->screen();
|
||||||
};
|
};
|
||||||
|
|
|
@ -505,11 +505,9 @@ void PipPanel::setPositionDefault() {
|
||||||
if (!widget) {
|
if (!widget) {
|
||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
if (!Platform::IsWayland()) {
|
if (const auto screen = QGuiApplication::screenAt(
|
||||||
if (const auto screen = QGuiApplication::screenAt(
|
|
||||||
widget->geometry().center())) {
|
widget->geometry().center())) {
|
||||||
return screen;
|
return screen;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return widget->screen();
|
return widget->screen();
|
||||||
};
|
};
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit fa8de8b199ae8b7569f8dec1c054325eff27ce45
|
Subproject commit 476d751251c8571e11260b7c712c885f4191d717
|
Loading…
Add table
Reference in a new issue