We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 25f714d commit 9ab80f4Copy full SHA for 9ab80f4
lib/src/dinamyc_star_menu.dart
@@ -0,0 +1,28 @@
1
+import 'package:flutter/material.dart';
2
+
3
+import 'star_menu.dart';
4
5
+class StarMenuOverlay {
6
+ // Build the StarMenu on an overlay
7
+ static displayStarMenu(BuildContext context, StarMenu starMenu) {
8
+ // Retrieve the parent Overlay
9
+ OverlayState? _overlayState = Overlay.of(context);
10
11
+ // Generate the Stack containing all StarItems that will
12
+ // be displayed onto the Overlay
13
+ OverlayEntry _overlayEntry = OverlayEntry(
14
+ builder: (BuildContext context) {
15
+ return Stack(
16
+ children: <Widget>[
17
+ starMenu,
18
+ ],
19
+ );
20
+ },
21
22
23
24
+ // Add it to the Overlay
25
+ _overlayState!.insert(_overlayEntry);
26
27
+ }
28
+}
0 commit comments