File tree Expand file tree Collapse file tree
packages/material_ui/lib/src Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -3697,13 +3697,11 @@ class _MenuPanelState extends State<_MenuPanel> {
36973697 final EdgeInsetsGeometry padding =
36983698 resolve <EdgeInsetsGeometry ?>((MenuStyle ? style) => style? .padding) ?? EdgeInsets .zero;
36993699 final Offset densityAdjustment = visualDensity.baseSizeAdjustment;
3700- // Material's Scrollbar uses the ambient MediaQuery padding as its painter
3701- // padding when no explicit padding is given, so that the thumb clears
3702- // system intrusions such as a gesture bar. The menu overlay is already
3703- // positioned inside the safe area, so honoring that padding a second time
3704- // shortens the scrollbar track and stops the thumb from reaching the end of
3705- // the menu. The padding is therefore removed for the Scrollbar only and
3706- // restored below it, so menu children keep observing the ambient values.
3700+ // Scrollbar uses the `MediaQuery.padding` as its painter padding by
3701+ // default. Menu overlays are already positioned within the safe area, so
3702+ // applying that padding again shortens the scrollbar track and stops the
3703+ // thumb from reaching the end of the menu. Remove the padding only for the
3704+ // Scrollbar and restore the ambient MediaQuery for menu children.
37073705 final MediaQueryData ambientMediaQuery = MediaQuery .of (context);
37083706 final MediaQueryData scrollbarMediaQuery = ambientMediaQuery.removePadding (
37093707 removeLeft: true ,
You can’t perform that action at this time.
0 commit comments