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

Workaround WinUI bug with adding/removing flyouts #14985

Merged
merged 1 commit into from Jun 16, 2023

Conversation

PureWeen
Copy link
Member

@PureWeen PureWeen commented May 8, 2023

Description of Change

Workaround an issue in WinUI where you can't add/remove flyout items to a submenu.

The fix was a bit more involved than I'd hoped it would be. You basically have to remove the SubMenuItem and recreate the entire thing in order to modify the menu. At least that's the only way I could get it to work.

  • If you just remove/add the item it doesn't work
  • If you try to move any children menu from the old menu to the new menu it just crashes.

Issues Fixed

Fixes #14984

Testing

This is all visual so we can't really use our device tests for this

@Eilon Eilon added the area/controls 🎮 Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor label Jun 8, 2023
@PureWeen PureWeen requested a review from jsuarezruiz June 9, 2023 00:34
Copy link
Member

@rachelkang rachelkang left a comment

Choose a reason for hiding this comment

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

validated fix and LGTM

@rachelkang rachelkang merged commit cc1730a into main Jun 16, 2023
29 checks passed
@rachelkang rachelkang deleted the fix_add_flyout_items_windows branch June 16, 2023 16:05
@github-actions github-actions bot locked and limited conversation to collaborators Dec 10, 2023
@Eilon Eilon removed the area/controls 🎮 Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor label May 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Windows] Adding and Removing ContextMenus currently does not work
4 participants