Guest User

Untitled

a guest
Dec 12th, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.09 KB | None | 0 0
  1. OverlayEntry _buildOverlayFeedback(BuildContext context, String tituloEvento) {
  2. return OverlayEntry(
  3. builder: (context) => Material(
  4. child: Container(
  5. width: double.infinity,
  6. height: double.infinity,
  7. child: Column(
  8. mainAxisAlignment: MainAxisAlignment.center,
  9. children: <Widget>[
  10. Column(
  11. children: <Widget>[
  12. ListTile(
  13. leading: Icon(Icons.sentiment_dissatisfied),
  14. title: Text('No me ha gustado'),
  15. onTap: () {
  16. // how to close myself????
  17. },
  18. ),
  19. ListTile(
  20. leading: Icon(Icons.sentiment_very_satisfied),
  21. title: Text('Muy bien'),
  22. onTap: () {}),
  23. ],
  24. ),
  25. ],
  26. ),
  27. ),
  28. ),
  29. );
  30. }
  31.  
  32. OverlayEntry _buildOverlayFeedback(BuildContext context, String tituloEvento) {
  33. OverlayEntry entry;
  34. entry = OverlayEntry(
  35. builder: (context) => Material(
  36. child: Container(
  37. width: double.infinity,
  38. height: double.infinity,
  39. child: Column(
  40. mainAxisAlignment: MainAxisAlignment.center,
  41. children: <Widget>[
  42. Column(
  43. children: <Widget>[
  44. ListTile(
  45. leading: Icon(Icons.sentiment_dissatisfied),
  46. title: Text('No me ha gustado'),
  47. onTap: () {
  48. entry.remove();
  49. },
  50. ),
  51. ListTile(
  52. leading: Icon(Icons.sentiment_very_satisfied),
  53. title: Text('Muy bien'),
  54. onTap: () {}),
  55. ],
  56. ),
  57. ],
  58. ),
  59. ),
  60. ),
  61. );
  62. return entry;
  63. }
Add Comment
Please, Sign In to add comment