-
Notifications
You must be signed in to change notification settings - Fork 1.1k
fix issues#12941 Combox autocomplete list weird selection behaviour #12999
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
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2435,6 +2435,16 @@ protected virtual void OnDropDown(EventArgs e) | |
[EditorBrowsable(EditorBrowsableState.Advanced)] | ||
protected override void OnKeyDown(KeyEventArgs e) | ||
{ | ||
// for fix https://github.com/dotnet/winforms/issues/12941 | ||
char input = (char)e.KeyValue; | ||
if ((AutoCompleteMode == AutoCompleteMode.Suggest || AutoCompleteMode == AutoCompleteMode.SuggestAppend) && | ||
!char.IsControl(input)) | ||
{ | ||
DroppedDown = false; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This change in behavior might not work for some users. For example, if the autocomplete list is not displayed because what the user types is not in the drop-down list, we shouldn't close the drop down. I would rather not fix it. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm going to have to agree here. I don't like that change in behavior. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ok I will close this PR, maybe someday I will pick it up 🤣 |
||
} | ||
|
||
// End fix | ||
|
||
// Do Return/ESC handling | ||
if (SystemAutoCompleteEnabled) | ||
{ | ||
|
Uh oh!
There was an error while loading. Please reload this page.