diff --git a/src/xdgshellwindow.cpp b/src/xdgshellwindow.cpp index f3a552d36a..918599c90c 100644 --- a/src/xdgshellwindow.cpp +++ b/src/xdgshellwindow.cpp @@ -1644,9 +1644,12 @@ bool XdgPopupWindow::hasTransientPlacementHint() const QRectF XdgPopupWindow::transientPlacement(const QRectF &bounds) const { const XdgPositioner positioner = m_shellSurface->positioner(); - const QSize desiredSize = positioner.size(); + if (m_plasmaShellSurface && m_plasmaShellSurface->isPositionSet()) { + return QRectF(m_plasmaShellSurface->position(), desiredSize); + } + const QPointF parentPosition = transientFor()->framePosToClientPos(transientFor()->pos()); // returns if a target is within the supplied bounds, optional edges argument states which side to check