input: allow setting cursor even if it's hidden

ref #4197
This commit is contained in:
Vaxry 2023-12-20 13:00:27 +01:00
parent 3771c49a94
commit d1b8a63a8e

View file

@ -2031,9 +2031,9 @@ void CHyprRenderer::setCursorSurface(wlr_surface* surf, int hotspotX, int hotspo
m_sLastCursorData.hotspotX = hotspotX;
m_sLastCursorData.hotspotY = hotspotY;
if (shouldRenderCursor() || !surf)
wlr_cursor_set_surface(g_pCompositor->m_sWLRCursor, surf, hotspotX, hotspotY);
}
void CHyprRenderer::setCursorFromName(const std::string& name) {
m_bCursorHasSurface = true;
@ -2043,7 +2043,6 @@ void CHyprRenderer::setCursorFromName(const std::string& name) {
m_sLastCursorData.name = name;
m_sLastCursorData.surf.reset();
if (shouldRenderCursor())
wlr_cursor_set_xcursor(g_pCompositor->m_sWLRCursor, g_pCompositor->m_sWLRXCursorMgr, name.c_str());
}