summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAxel Davy <[email protected]>2015-03-21 22:28:59 +0100
committerAxel Davy <[email protected]>2015-08-21 22:21:45 +0200
commita30684712ee9a3ef6738de8c357134a01a24924c (patch)
tree1893fe54af5ee4ecd556f5f5c9b59f3560549871
parentdf6f1f77cc63db3e6a7c105f3e7bab246b576eb9 (diff)
st/nine: Revert to sw cursor in case of failure to set hw cursor
Signed-off-by: Axel Davy <[email protected]> Reviewed-by: David Heidelberg <[email protected]>
-rw-r--r--src/gallium/state_trackers/nine/device9.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gallium/state_trackers/nine/device9.c b/src/gallium/state_trackers/nine/device9.c
index 9f6c90ed50b..38af8e3bc58 100644
--- a/src/gallium/state_trackers/nine/device9.c
+++ b/src/gallium/state_trackers/nine/device9.c
@@ -682,7 +682,7 @@ NineDevice9_SetCursorPosition( struct NineDevice9 *This,
This->cursor.pos.y = Y;
if (!This->cursor.software)
- ID3DPresent_SetCursorPos(swap->present, &This->cursor.pos);
+ This->cursor.software = ID3DPresent_SetCursorPos(swap->present, &This->cursor.pos) != D3D_OK;
}
BOOL WINAPI
@@ -695,7 +695,7 @@ NineDevice9_ShowCursor( struct NineDevice9 *This,
This->cursor.visible = bShow && (This->cursor.hotspot.x != -1);
if (!This->cursor.software)
- ID3DPresent_SetCursor(This->swapchains[0]->present, NULL, NULL, bShow);
+ This->cursor.software = ID3DPresent_SetCursor(This->swapchains[0]->present, NULL, NULL, bShow) != D3D_OK;
return old;
}