|
@@ -34,14 +34,14 @@ import 'package:photos/utils/toast_util.dart';
|
|
|
|
|
|
class FadingAppBar extends StatefulWidget implements PreferredSizeWidget {
|
|
|
final File file;
|
|
|
- final Function(File) onFileDeleted;
|
|
|
+ final Function(File) onFileRemoved;
|
|
|
final double height;
|
|
|
final bool shouldShowActions;
|
|
|
final int userID;
|
|
|
|
|
|
const FadingAppBar(
|
|
|
this.file,
|
|
|
- this.onFileDeleted,
|
|
|
+ this.onFileRemoved,
|
|
|
this.userID,
|
|
|
this.height,
|
|
|
this.shouldShowActions, {
|
|
@@ -260,7 +260,7 @@ class FadingAppBarState extends State<FadingAppBar> {
|
|
|
final hideResult =
|
|
|
await CollectionsService.instance.hideFiles(context, [widget.file]);
|
|
|
if (hideResult) {
|
|
|
- widget.onFileDeleted(widget.file);
|
|
|
+ widget.onFileRemoved(widget.file);
|
|
|
}
|
|
|
} catch (e, s) {
|
|
|
_logger.severe("failed to update file visibility", e, s);
|
|
@@ -352,7 +352,7 @@ class FadingAppBarState extends State<FadingAppBar> {
|
|
|
onPressed: () async {
|
|
|
await deleteFilesFromEverywhere(context, [file]);
|
|
|
Navigator.of(context, rootNavigator: true).pop();
|
|
|
- widget.onFileDeleted(file);
|
|
|
+ widget.onFileRemoved(file);
|
|
|
},
|
|
|
child: const Text("Everywhere"),
|
|
|
),
|
|
@@ -391,7 +391,7 @@ class FadingAppBarState extends State<FadingAppBar> {
|
|
|
onPressed: () async {
|
|
|
await deleteFilesFromEverywhere(context, [file]);
|
|
|
Navigator.of(context, rootNavigator: true).pop();
|
|
|
- widget.onFileDeleted(file);
|
|
|
+ widget.onFileRemoved(file);
|
|
|
},
|
|
|
child: const Text("Everywhere"),
|
|
|
),
|