Skip to content

Conversation

@gspencergoog
Copy link
Contributor

@gspencergoog gspencergoog commented Jan 28, 2022

Description

This implements a prototype of MenuBar widgets that can both render a Material menu bar, and speak to a bundled plugin on the engine that will create and manage system generated menu bars on macOS, Windows, and Linux (a.k.a. PlatformMenuBar, submitted already).

This implementation of the MenuBar uses a MenuBarController to manager most of the communincation between widgets that need to occur to implement the menu bar. The MenuBar uses a hierarchy of MenuBarItem widgets which extend MenuItem so that they are also useful for configuring a platform provided menu.

For the Material MenuBar, MenuBarItem widgets have an internal _MenuNode assigned by looking for a wrapping _MenuNodeWrapper, and then they register attributes with that node (things like the focus node associated with the button, and the menu builder function for the submenus).

Related Issues

Tests

  • Many tests for all of the MenuBar operations and configuration.

Design Doc

@flutter-dashboard flutter-dashboard bot added f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels. c: contributor-productivity Team-specific productivity, code health, technical debt. labels Jan 28, 2022
@gspencergoog gspencergoog force-pushed the menu_bar branch 2 times, most recently from e348136 to ee1b4f2 Compare January 28, 2022 01:04
@gspencergoog gspencergoog force-pushed the menu_bar branch 12 times, most recently from 3e8f18b to 3dd2c1a Compare February 1, 2022 18:15
@gspencergoog gspencergoog force-pushed the menu_bar branch 5 times, most recently from 1331e21 to ccac0ae Compare February 5, 2022 03:18
@gspencergoog gspencergoog added the a: desktop Running on desktop label Feb 15, 2022
@skia-gold
Copy link

Gold has detected about 38 new digest(s) on patchset 15.
View them at https://flutter-gold.skia.org/cl/github/97408

@gspencergoog gspencergoog force-pushed the menu_bar branch 2 times, most recently from bf221e8 to 064e773 Compare February 18, 2022 03:12
@gspencergoog gspencergoog force-pushed the menu_bar branch 2 times, most recently from ebda9e5 to ec20ae6 Compare May 12, 2022 16:30
@flutter-dashboard flutter-dashboard bot added the f: gestures flutter/packages/flutter/gestures repository. label May 13, 2022
@gspencergoog gspencergoog force-pushed the menu_bar branch 8 times, most recently from da3754e to ee5006b Compare May 20, 2022 01:02
@gspencergoog gspencergoog force-pushed the menu_bar branch 14 times, most recently from a799de7 to aa6ec6e Compare May 25, 2022 21:51
@gspencergoog
Copy link
Contributor Author

Closing this to start a new one without all the history.

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

Labels

a: desktop Running on desktop c: contributor-productivity Team-specific productivity, code health, technical debt. d: api docs Issues with https://api.flutter.dev/ d: examples Sample code and demos f: focus Focus traversal, gaining or losing focus f: gestures flutter/packages/flutter/gestures repository. f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants