Henri Verbeet : wined3d: Use the resource map/ unmap functions in wined3d_device_set_cursor_properties().
Alexandre Julliard
julliard at wine.codeweavers.com
Tue Mar 8 08:03:02 CST 2016
Module: wine
Branch: master
Commit: 60865da5a5d18aca7addf63582c3a79efc42ccf6
URL: http://source.winehq.org/git/wine.git/?a=commit;h=60865da5a5d18aca7addf63582c3a79efc42ccf6
Author: Henri Verbeet <hverbeet at codeweavers.com>
Date: Mon Mar 7 17:05:52 2016 +0100
wined3d: Use the resource map/unmap functions in wined3d_device_set_cursor_properties().
Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/wined3d/device.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c
index fbbbc2c..f094752 100644
--- a/dlls/wined3d/device.c
+++ b/dlls/wined3d/device.c
@@ -4340,7 +4340,8 @@ HRESULT CDECL wined3d_device_set_cursor_properties(struct wined3d_device *device
return E_OUTOFMEMORY;
memset(mask_bits, 0xff, mask_size);
- wined3d_surface_map(cursor_image, &map_desc, NULL, WINED3D_MAP_NO_DIRTY_UPDATE | WINED3D_MAP_READONLY);
+ wined3d_resource_map(&texture->resource, sub_resource_idx, &map_desc, NULL,
+ WINED3D_MAP_NO_DIRTY_UPDATE | WINED3D_MAP_READONLY);
cursor_info.fIcon = FALSE;
cursor_info.xHotspot = x_hotspot;
cursor_info.yHotspot = y_hotspot;
@@ -4348,7 +4349,7 @@ HRESULT CDECL wined3d_device_set_cursor_properties(struct wined3d_device *device
cursor_image->resource.height, 1, 1, mask_bits);
cursor_info.hbmColor = CreateBitmap(cursor_image->resource.width,
cursor_image->resource.height, 1, 32, map_desc.data);
- wined3d_surface_unmap(cursor_image);
+ wined3d_resource_unmap(&texture->resource, sub_resource_idx);
/* Create our cursor and clean up. */
cursor = CreateIconIndirect(&cursor_info);
More information about the wine-cvs
mailing list