mirror of
https://github.com/gnif/LookingGlass.git
synced 2024-11-25 23:07:18 +00:00
[c-host] dxgi: invisible cursors do not have position information
This commit is contained in:
parent
8745858bcf
commit
fea0a98b9e
@ -710,15 +710,19 @@ static CaptureResult dxgi_capture()
|
|||||||
frameInfo.PointerPosition.Visible != this->lastPointerVisible
|
frameInfo.PointerPosition.Visible != this->lastPointerVisible
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
pointer.positionUpdate = true;
|
pointer.positionUpdate = true;
|
||||||
this->lastPointerX = frameInfo.PointerPosition.Position.x;
|
|
||||||
this->lastPointerY = frameInfo.PointerPosition.Position.y;
|
/* the pointer position is invalid if the pointer is not visible */
|
||||||
|
if (frameInfo.PointerPosition.Visible)
|
||||||
|
{
|
||||||
|
this->lastPointerX = frameInfo.PointerPosition.Position.x;
|
||||||
|
this->lastPointerY = frameInfo.PointerPosition.Position.y;
|
||||||
|
}
|
||||||
this->lastPointerVisible = frameInfo.PointerPosition.Visible;
|
this->lastPointerVisible = frameInfo.PointerPosition.Visible;
|
||||||
|
|
||||||
pointer.x = this->lastPointerX;
|
pointer.x = this->lastPointerX;
|
||||||
pointer.y = this->lastPointerY;
|
pointer.y = this->lastPointerY;
|
||||||
pointer.visible = this->lastPointerVisible;
|
pointer.visible = this->lastPointerVisible;
|
||||||
|
|
||||||
postPointer = true;
|
postPointer = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user