7 Apr
2015
7 Apr
'15
9:17 a.m.
Aric Stewart <aric(a)codeweavers.com> wrote:
+ if (SUCCEEDED(IDirectInputDevice2_GetProperty(iface, DIPROP_JOYSTICKID, (LPDIPROPHEADER)&pd))) + index = pd.dwData;
Please find a way to avoid the cast.
+ if (SUCCEEDED(IDirectInputDevice2_GetProperty(iface, DIPROP_JOYSTICKID, (LPDIPROPHEADER)&pd))) + index = pd.dwData;
Same here.
+ snprintf(buffer, MAX_PATH, "Joystick %d", index);
'index' is unsigned, sizeof() instead of a hardcoded value is better. -- Dmitry.