mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-30 14:17:45 +00:00
Don't set geometry for media viewer only on Wayland
This commit is contained in:
@@ -450,15 +450,13 @@ void OverlayWidget::moveToScreen() {
|
|||||||
.arg(screenList.indexOf(activeWindowScreen)));
|
.arg(screenList.indexOf(activeWindowScreen)));
|
||||||
windowHandle()->setScreen(activeWindowScreen);
|
windowHandle()->setScreen(activeWindowScreen);
|
||||||
DEBUG_LOG(("Viewer Pos: New actual screen: %1")
|
DEBUG_LOG(("Viewer Pos: New actual screen: %1")
|
||||||
.arg(windowHandle()
|
.arg(screenList.indexOf(windowHandle()->screen())));
|
||||||
? screenList.indexOf(windowHandle()->screen())
|
|
||||||
: -2));
|
|
||||||
}
|
}
|
||||||
updateGeometry();
|
updateGeometry();
|
||||||
}
|
}
|
||||||
|
|
||||||
void OverlayWidget::updateGeometry() {
|
void OverlayWidget::updateGeometry() {
|
||||||
if (Platform::IsLinux()) {
|
if (Platform::IsWayland()) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const auto screen = windowHandle() && windowHandle()->screen()
|
const auto screen = windowHandle() && windowHandle()->screen()
|
||||||
@@ -1323,9 +1321,7 @@ void OverlayWidget::handleVisibleChanged(bool visible) {
|
|||||||
if (visible) {
|
if (visible) {
|
||||||
const auto screenList = QGuiApplication::screens();
|
const auto screenList = QGuiApplication::screens();
|
||||||
DEBUG_LOG(("Viewer Pos: Shown, screen number: %1")
|
DEBUG_LOG(("Viewer Pos: Shown, screen number: %1")
|
||||||
.arg(windowHandle()
|
.arg(screenList.indexOf(windowHandle()->screen())));
|
||||||
? screenList.indexOf(windowHandle()->screen())
|
|
||||||
: -2));
|
|
||||||
|
|
||||||
moveToScreen();
|
moveToScreen();
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user