Skip to content

bugfix (com_dotnet) LOCALE constant for IDispatch #7391

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from

Conversation

DmitryMaksimov
Copy link
Contributor

Changing some remaining LOCALE_SYSTEM_DEFAULT to LANG_NEUTRAL

Changing some remaining LOCALE_SYSTEM_DEFAULT to LANG_NEUTRAL
@DmitryMaksimov
Copy link
Contributor Author

Need testing

@DmitryMaksimov
Copy link
Contributor Author

DmitryMaksimov commented Aug 21, 2021

Testing done on Windows 10

Copy link
Member

@cmb69 cmb69 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, right, using LOCALE_SYSTEM_DEFAULT here might indeed not be the best idea (especially wrt. DCOM). However, shouldn't it be MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT) instead of LANG_NEUTRAL?

@DmitryMaksimov
Copy link
Contributor Author

Ah, right, using LOCALE_SYSTEM_DEFAULT here might indeed not be the best idea (especially wrt. DCOM). However, shouldn't it be MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT) instead of LANG_NEUTRAL?

even better like this:
MAKELANGID(LANG_NEUTRAL, SUBLANG_NEUTRAL)

@DmitryMaksimov
Copy link
Contributor Author

winnt.h:
#define MAKELANGID(p, s) ((((WORD )(s)) << 10) | (WORD )(p))
LANG_NEUTRAL must be enouth

@cmb69
Copy link
Member

cmb69 commented Aug 23, 2021

Yes, we could also use 0, but I think using the documented MAKELCID() macro is preferable.

Copy link
Member

@cmb69 cmb69 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants