-
Notifications
You must be signed in to change notification settings - Fork 1k
Moving common logic of keyboard's simulation into the helper class. #7537
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
Moving common logic of keyboard's simulation into the helper class. #7537
Conversation
Moving to .NET8 because this is a refactoring and does not meet the bar for .net7 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, I added a few nits. Please don't merge until main becomes a NET8 branch
d4f85a9
to
ebb65a8
Compare
ebb65a8
to
246e199
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! ✅
// https://docs.microsoft.com/windows/win32/inputdev/wm-keyup | ||
// The MSDN page tells us what bits of lParam to use for each of the parameters. | ||
// All we need to do is some bit shifting to assemble lParam | ||
// lParam = repeatCount | (scanCode << 16) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: this is different with the code below. So, I would just remove this line. We see lParam
below.
src/System.Windows.Forms/tests/TestUtilities/KeyboardSimulator.cs
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please replace ToInt with FromLowHighUnsigned
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚀
0b23ab7
246e199
to
0b23ab7
Compare
Please rebase to the latest main to resolve build errors |
…to the helper class.
a63940c
0b23ab7
to
a63940c
Compare
@vladimir-krestov - you should be able to re-run build by adding a |
@Tanya-Solyanik this change only affects the test infra, is there any reason not to have this merged? |
good point |
Fixes #7506
Proposed changes
Customer Impact
Regression?
Risk
Test methodology
Test environment(s)
Microsoft Reviewers: Open in CodeFlow