mirror of
https://github.com/venera-app/venera.git
synced 2025-09-27 07:47:24 +00:00
universal: style improvements (#67)
This commit is contained in:
@@ -231,7 +231,10 @@ class _BodyState extends State<_Body> {
|
||||
showConfirmDialog(
|
||||
context: App.rootContext,
|
||||
title: "Delete".tl,
|
||||
content: "Are you sure you want to delete it?".tl,
|
||||
content: "Delete comic source '@n' ?".tlParams({
|
||||
"n": source.name,
|
||||
}),
|
||||
btnColor: context.colorScheme.error,
|
||||
onConfirm: () {
|
||||
var file = File(source.filePath);
|
||||
file.delete();
|
||||
|
@@ -149,22 +149,6 @@ class _LocalFavoritesPageState extends State<_LocalFavoritesPage> {
|
||||
),
|
||||
MenuButton(
|
||||
entries: [
|
||||
MenuEntry(
|
||||
icon: Icons.delete_outline,
|
||||
text: "Delete Folder".tl,
|
||||
onClick: () {
|
||||
showConfirmDialog(
|
||||
context: App.rootContext,
|
||||
title: "Delete".tl,
|
||||
content:
|
||||
"Are you sure you want to delete this folder?".tl,
|
||||
onConfirm: () {
|
||||
favPage.setFolder(false, null);
|
||||
LocalFavoritesManager().deleteFolder(widget.folder);
|
||||
favPage.folderList?.updateFolders();
|
||||
},
|
||||
);
|
||||
}),
|
||||
MenuEntry(
|
||||
icon: Icons.edit_outlined,
|
||||
text: "Rename".tl,
|
||||
@@ -233,6 +217,26 @@ class _LocalFavoritesPageState extends State<_LocalFavoritesPage> {
|
||||
}
|
||||
});
|
||||
}),
|
||||
MenuEntry(
|
||||
icon: Icons.delete_outline,
|
||||
text: "Delete Folder".tl,
|
||||
color: context.colorScheme.error,
|
||||
onClick: () {
|
||||
showConfirmDialog(
|
||||
context: App.rootContext,
|
||||
title: "Delete".tl,
|
||||
content:
|
||||
"Delete folder '@f' ?".tlParams({
|
||||
"f": widget.folder,
|
||||
}),
|
||||
btnColor: context.colorScheme.error,
|
||||
onConfirm: () {
|
||||
favPage.setFolder(false, null);
|
||||
LocalFavoritesManager().deleteFolder(widget.folder);
|
||||
favPage.folderList?.updateFolders();
|
||||
},
|
||||
);
|
||||
}),
|
||||
],
|
||||
),
|
||||
],
|
||||
@@ -256,12 +260,12 @@ class _LocalFavoritesPageState extends State<_LocalFavoritesPage> {
|
||||
actions: [
|
||||
MenuButton(entries: [
|
||||
MenuEntry(
|
||||
icon: Icons.star,
|
||||
text: "Add to favorites".tl,
|
||||
icon: Icons.drive_file_move,
|
||||
text: "Move to folder".tl,
|
||||
onClick: () => favoriteOption('move')),
|
||||
MenuEntry(
|
||||
icon: Icons.drive_file_move,
|
||||
text: "Move to favorites".tl,
|
||||
icon: Icons.copy,
|
||||
text: "Copy to folder".tl,
|
||||
onClick: () => favoriteOption('add')),
|
||||
MenuEntry(
|
||||
icon: Icons.select_all,
|
||||
@@ -277,13 +281,15 @@ class _LocalFavoritesPageState extends State<_LocalFavoritesPage> {
|
||||
onClick: invertSelection),
|
||||
MenuEntry(
|
||||
icon: Icons.delete_outline,
|
||||
text: "Delete Folder".tl,
|
||||
text: "Delete Comic".tl,
|
||||
color: context.colorScheme.error,
|
||||
onClick: () {
|
||||
showConfirmDialog(
|
||||
context: context,
|
||||
title: "Delete".tl,
|
||||
content:
|
||||
"Are you sure you want to delete this comic?".tl,
|
||||
"Delete @c comics?".tlParams({"c": selectedComics.length}),
|
||||
btnColor: context.colorScheme.error,
|
||||
onConfirm: () {
|
||||
_deleteComicWithId();
|
||||
},
|
||||
|
@@ -19,8 +19,8 @@ Future<bool> _deleteComic(
|
||||
bool loading = false;
|
||||
return StatefulBuilder(builder: (context, setState) {
|
||||
return ContentDialog(
|
||||
title: "Delete".tl,
|
||||
content: Text("Are you sure you want to delete this comic?".tl)
|
||||
title: "Remove".tl,
|
||||
content: Text("Remove comic from favorite?".tl)
|
||||
.paddingHorizontal(16),
|
||||
actions: [
|
||||
Button.filled(
|
||||
@@ -424,7 +424,7 @@ class _FolderTile extends StatelessWidget {
|
||||
return StatefulBuilder(builder: (context, setState) {
|
||||
return ContentDialog(
|
||||
title: "Delete".tl,
|
||||
content: Text("Are you sure you want to delete this folder?".tl)
|
||||
content: Text("Delete folder?".tl)
|
||||
.paddingHorizontal(16),
|
||||
actions: [
|
||||
Button.filled(
|
||||
|
@@ -111,6 +111,7 @@ class _HistoryPageState extends State<HistoryPage> {
|
||||
MenuEntry(
|
||||
icon: Icons.remove,
|
||||
text: 'Remove'.tl,
|
||||
color: context.colorScheme.error,
|
||||
onClick: () {
|
||||
if (c.sourceKey.startsWith("Invalid")) {
|
||||
HistoryManager().remove(
|
||||
|
Reference in New Issue
Block a user