Skip to content

Commit

Permalink
UI: Replace Material based designs with scrawler there
Browse files Browse the repository at this point in the history
  • Loading branch information
Nandanrmenon committed Sep 21, 2023
1 parent c527eb9 commit 2cce8d5
Showing 1 changed file with 17 additions and 18 deletions.
35 changes: 17 additions & 18 deletions lib/mobile/pages/mobile_notes_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -183,22 +183,24 @@ class _MobileNotesPageState extends State<MobileNotesPage> {
}

void showOptions(BuildContext context, Notes note) {
showModalBottomSheet(
showDragHandle: true,
showDialog(
context: context,
builder: (context) {
return Container(
padding: kGlobalOuterPadding,
child: ListView.builder(
itemCount: contextMenuItems.length,
itemBuilder: (context, index) {
return ListTile(
onTap: () =>
onContextSelected(contextMenuItems[index].value, note),
leading: Icon(contextMenuItems[index].icon),
title: Text(contextMenuItems[index].caption),
);
}),
return Dialog(
child: Container(
padding: kGlobalOuterPadding,
child: ListView.builder(
shrinkWrap: true,
itemCount: contextMenuItems.length,
itemBuilder: (context, index) {
return ListTile(
onTap: () => onContextSelected(
contextMenuItems[index].value, note),
leading: Icon(contextMenuItems[index].icon),
title: Text(contextMenuItems[index].caption),
);
}),
),
);
});
}
Expand Down Expand Up @@ -240,10 +242,7 @@ class _MobileNotesPageState extends State<MobileNotesPage> {
onPressed: () => Navigator.pop(context),
)
],
titlePadding: EdgeInsets.zero,
title: const YaruDialogTitleBar(
title: Text('Confirm'),
),
title: const Text('Confirm'),
content: const Text('Are you sure you want to delete?'),
);
});
Expand Down

0 comments on commit 2cce8d5

Please sign in to comment.