popover icon indicating copy to clipboard operation
popover copied to clipboard

Popover doesn't show up from AppBar

Open murad1981 opened this issue 3 years ago • 4 comments

when the showPopOver method is called from an IconButton placed in the AppBar the popover doesn't show up, my app bar looks like this:

AppBar(
          title: const Text('Popover Example'),
          actions: [
            IconButton(
              icon: Icon(Icons.sort),
              onPressed: () {
                showPopover(
                  context: context,
                  bodyBuilder: (context) => const ListItems(),
                  onPop: () => print('Popover was popped!'),
                  direction: PopoverDirection.top,
                  width: 200,
                  height: 400,
                  arrowHeight: 15,
                  arrowWidth: 30,
                );
              },
            ),
          ],
        )

murad1981 avatar Feb 06 '22 05:02 murad1981

@murad1981 Any Solution for this?

balajiks-dev avatar Jul 02 '22 03:07 balajiks-dev

@murad1981 Any update?

shanu95 avatar Jul 07 '22 10:07 shanu95

@murad1981 It worked when wrapped with Builder. Try wrapping your widget with a Builder.

shanu95 avatar Jul 07 '22 11:07 shanu95

+1

zhangyc avatar Aug 03 '22 02:08 zhangyc

Please, see this discussion.

minikin avatar Oct 01 '22 15:10 minikin