mirror of
https://github.com/narzoul/DDrawCompat
synced 2024-12-30 08:55:36 +01:00
Remove DPI scaling for emulated hardware cursors
This commit is contained in:
parent
d9273c654d
commit
7019ea18c9
@ -117,6 +117,21 @@ namespace D3dDdi
|
|||||||
if (cursor != m_cursor)
|
if (cursor != m_cursor)
|
||||||
{
|
{
|
||||||
m_cursor = cursor;
|
m_cursor = cursor;
|
||||||
|
|
||||||
|
std::unique_ptr<HICON__, decltype(&DestroyCursor)> resizedCursor(reinterpret_cast<HCURSOR>(
|
||||||
|
CopyImage(cursor, IMAGE_CURSOR, 32, 32, LR_COPYRETURNORG | LR_COPYFROMRESOURCE)), DestroyCursor);
|
||||||
|
if (resizedCursor)
|
||||||
|
{
|
||||||
|
if (resizedCursor.get() == cursor)
|
||||||
|
{
|
||||||
|
resizedCursor.release();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
cursor = resizedCursor.get();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
ICONINFO iconInfo = {};
|
ICONINFO iconInfo = {};
|
||||||
if (!GetIconInfo(cursor, &iconInfo))
|
if (!GetIconInfo(cursor, &iconInfo))
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user