diff --git a/x11/plasma6-layer-shell-qt/Makefile b/x11/plasma6-layer-shell-qt/Makefile index 7d07e029f098..30f4a19b164f 100644 --- a/x11/plasma6-layer-shell-qt/Makefile +++ b/x11/plasma6-layer-shell-qt/Makefile @@ -1,18 +1,19 @@ PORTNAME= layer-shell-qt DISTVERSION= ${KDE_PLASMA_VERSION} +PORTREVISION= 1 CATEGORIES= x11 kde kde-plasma COMMENT= Qt component to allow applications to make use of the Wayland wl-layer-shell protocol MAINTAINER= kde@FreeBSD.org BUILD_DEPENDS= wayland-protocols>0:graphics/wayland-protocols LIB_DEPENDS= libwayland-client.so:graphics/wayland \ libxkbcommon.so:x11/libxkbcommon USES= cmake gl kde:6 pkgconfig qt:6 tar:xz USE_GL= gl opengl USE_KDE= ecm:build USE_QT= base wayland .include diff --git a/x11/plasma6-layer-shell-qt/files/patch-src_qwaylandlayersurface.cpp b/x11/plasma6-layer-shell-qt/files/patch-src_qwaylandlayersurface.cpp new file mode 100644 index 000000000000..264ac398bdcd --- /dev/null +++ b/x11/plasma6-layer-shell-qt/files/patch-src_qwaylandlayersurface.cpp @@ -0,0 +1,17 @@ +Fix the crash that happens when right-clicking the desktop surface + +--- src/qwaylandlayersurface.cpp.orig 2025-07-15 09:53:41 UTC ++++ src/qwaylandlayersurface.cpp +@@ -113,10 +113,8 @@ void QWaylandLayerSurface::attachPopup(QtWaylandClient + + void QWaylandLayerSurface::attachPopup(QtWaylandClient::QWaylandShellSurface *popup) + { +- std::any anyRole = popup->surfaceRole(); +- +- if (auto role = std::any_cast<::xdg_popup *>(&anyRole)) { +- get_popup(*role); ++ if (auto role = popup->nativeResource("xdg_popup")) { ++ get_popup(reinterpret_cast(role)); + } else { + qCWarning(LAYERSHELLQT) << "Cannot attach popup of unknown type"; + }