core: use new typed signals from hu (#10853)

This commit is contained in:
outfoxxed 2025-07-08 09:56:40 -07:00 committed by GitHub
parent 2f34ef141b
commit 78e9eddfb6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
85 changed files with 667 additions and 865 deletions

View file

@ -51,7 +51,7 @@ void CHyprlandSurface::setResource(SP<CHyprlandSurfaceV1> resource) {
m_visibleRegion = CWLRegionResource::fromResource(region)->m_region;
});
m_listeners.surfaceCommitted = m_surface->m_events.commit.registerListener([this](std::any data) {
m_listeners.surfaceCommitted = m_surface->m_events.commit.listen([this] {
auto surface = CWLSurface::fromResource(m_surface.lock());
if (surface && (surface->m_overallOpacity != m_opacity || m_visibleRegionChanged)) {
@ -67,7 +67,7 @@ void CHyprlandSurface::setResource(SP<CHyprlandSurfaceV1> resource) {
}
});
m_listeners.surfaceDestroyed = m_surface->m_events.destroy.registerListener([this](std::any data) {
m_listeners.surfaceDestroyed = m_surface->m_events.destroy.listen([this] {
if (!m_resource)
PROTO::hyprlandSurface->destroySurface(this);
});