Skip to content

Commit

Permalink
pointer: Include monitor scaling in HW hotspot calculation (#6283)
Browse files Browse the repository at this point in the history
  • Loading branch information
obivan authored May 31, 2024
1 parent a60c728 commit df6ebe3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/managers/PointerManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,7 @@ Vector2D CPointerManager::transformedHotspot(SP<CMonitor> pMonitor) {
if (!pMonitor->output->cursor_swapchain)
return {}; // doesn't matter, we have no hw cursor, and this is only for hw cursors

return CBox{currentCursorImage.hotspot, {0, 0}}
return CBox{currentCursorImage.hotspot * pMonitor->scale, {0, 0}}
.transform(wlr_output_transform_invert(pMonitor->transform), pMonitor->output->cursor_swapchain->width, pMonitor->output->cursor_swapchain->height)
.pos();
}
Expand Down

0 comments on commit df6ebe3

Please sign in to comment.