hyprland/surface: add visibleMask

This commit is contained in:
outfoxxed 2025-01-23 14:00:16 -08:00
parent cdaff2967f
commit b289bfa504
Signed by untrusted user: outfoxxed
GPG key ID: 4C88A185FB89301E
6 changed files with 230 additions and 36 deletions

View file

@ -1,21 +1,31 @@
#pragma once
#include <private/qwaylandwindow_p.h>
#include <qobject.h>
#include <qregion.h>
#include <qtclasshelpermacros.h>
#include <qtmetamacros.h>
#include <qtypes.h>
#include <qwayland-hyprland-surface-v1.h>
#include <wayland-client-protocol.h>
#include <wayland-hyprland-surface-v1-client-protocol.h>
namespace qs::hyprland::surface::impl {
class HyprlandSurface: public QtWayland::hyprland_surface_v1 {
public:
explicit HyprlandSurface(::hyprland_surface_v1* surface);
explicit HyprlandSurface(::hyprland_surface_v1* surface, QtWaylandClient::QWaylandWindow* backer);
~HyprlandSurface() override;
Q_DISABLE_COPY_MOVE(HyprlandSurface);
[[nodiscard]] bool surfaceEq(wl_surface* surface) const;
void setOpacity(qreal opacity);
void setVisibleRegion(const QRegion& region);
private:
QtWaylandClient::QWaylandWindow* backer;
wl_surface* backerSurface = nullptr;
};
} // namespace qs::hyprland::surface::impl