Skip to content

Commit c9aaa2a

Browse files
committed
Minor updates based on feedback
1 parent b938f4c commit c9aaa2a

File tree

3 files changed

+15
-7
lines changed

3 files changed

+15
-7
lines changed

lib/backend/fs.dart

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -282,10 +282,13 @@ class File implements Finalizable {
282282
);
283283
}
284284

285-
TransferFileOperation copy({required File to, Cancellable? cancellable}) {
285+
TransferFileOperation copy({
286+
required File destination,
287+
Cancellable? cancellable,
288+
}) {
286289
return TransferFileOperation._(
287290
source: this,
288-
destination: to,
291+
destination: destination,
289292
copy: true,
290293
cancellable: cancellable,
291294
);
@@ -324,10 +327,13 @@ class File implements Finalizable {
324327
);
325328
}
326329

327-
TransferFileOperation move({required File to, Cancellable? cancellable}) {
330+
TransferFileOperation move({
331+
required File destination,
332+
Cancellable? cancellable,
333+
}) {
328334
return TransferFileOperation._(
329335
source: this,
330-
destination: to,
336+
destination: destination,
331337
copy: false,
332338
cancellable: cancellable,
333339
);

lib/backend/utils.dart

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,8 @@ class Utils {
7878
directoryParts.parts..add(originParts.parts.last),
7979
originParts.separator,
8080
);
81-
return origin.move(to: fs.File.fromPath(destinationParts.toPath()));
81+
return origin.move(
82+
destination: fs.File.fromPath(destinationParts.toPath()),
83+
);
8284
}
8385
}

lib/widgets/entity_context_menu.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class EntityContextMenu extends StatelessWidget {
3131
const SingleActivator(LogicalKeyboardKey.keyC, control: true):
3232
onCopy!,
3333
if (onTrash != null)
34-
const SingleActivator(LogicalKeyboardKey.cancel): onTrash!,
34+
const SingleActivator(LogicalKeyboardKey.delete): onTrash!,
3535
},
3636
child: ContextMenu(
3737
entries: [
@@ -78,7 +78,7 @@ class EntityContextMenu extends StatelessWidget {
7878
leading: const Icon(YaruIcons.trash),
7979
child: const Text('Move to trash'),
8080
onTap: onTrash,
81-
shortcut: const SingleActivator(LogicalKeyboardKey.cancel),
81+
shortcut: const SingleActivator(LogicalKeyboardKey.delete),
8282
),
8383
],
8484
child: child,

0 commit comments

Comments
 (0)