Skip to content
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

Menu navigation working for the post part #262

Closed
wants to merge 1 commit into from

Conversation

floele-ww
Copy link
Contributor

Still not working: Focus WinForms Textbox, navigate into submenu and use
"Left" key to go back to the previous menu.

The System.Windows.Controls.MenuItem apparently doesn't want to handle the "Left" key but it's not really evident why that would be the case.

Still not working: Focus WinForms Textbox, navigate into submenu and use
"Left" key to go back to the previous menu.
@batzen
Copy link
Member

batzen commented Jan 31, 2016

To be honest i don't know what the purpose of the old code was.
On develop branch, without my changes:
I set a breakpoint in OnPreviewKeyDown of KeyTipAdorner where it talks about MenuItem.
Tried a few KeyTips on various elements and never ended up on the breakpoint.

Do you know what that code was supposed to do? I don't get it...
What's the purpose of your new code?
The old code said != MenuItem your new code says == MenuItem.

@floele-ww
Copy link
Contributor Author

Isn't the old code about "ContextMenu" rather? I don't know how context menus would be relevant for key tips either at the moment.
The purpose of my new code is to forward navigation keys (primarily arrow keys) to the currently opened menu item. It could make sense (maybe that's what the old code was about) to terminate KeyTips once manual navigation starts.
I tried a few other variants (like just leaving the keys unhandled) but that doesn't work for the WinForms case.

@batzen
Copy link
Member

batzen commented Feb 2, 2016

Ok, i had a look at the way Office 2016 handles keyboard navigation when keytips are visible.
I will try to implement a solution that works almost exactly as the one in Office 2016 which does not require modifications to any control.
I will take parts of your PR and will close it, are you ok with that?

@batzen
Copy link
Member

batzen commented Feb 2, 2016

Got a solution which works without control modification and for WinForms controls.
Just have to do some refactoring. Will push to the refactoring branch sometime this week.

@floele-ww
Copy link
Contributor Author

Sure, just take whatever you need and dispose of the rest. Thanks for your continued effort :)

@batzen
Copy link
Member

batzen commented Feb 3, 2016

Ok, will close this as i am pushing my changes now.
Could you do some testing and report issues in #258?
I already tested this and couldn't find any bugs.

@batzen batzen closed this Feb 3, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants