Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Remove feature flags for guestview and addToAlbum

Neeraj Gupta757d2f952207
diff --git a/mobile/apps/photos/lib/ui/viewer/file/file_app_bar.dart b/mobile/apps/photos/lib/ui/viewer/file/file_app_bar.dart
index 6753032ca8..512e005e2d 100644
--- a/mobile/apps/photos/lib/ui/viewer/file/file_app_bar.dart
+++ b/mobile/apps/photos/lib/ui/viewer/file/file_app_bar.dart
@@ -222,13 +222,11 @@ class FileAppBarState extends State<FileAppBar> {
),
);
}
- // Add to album option for uploaded files (behind feature flag)
- if (flagService.addToAlbumFeature &&
- widget.file.isUploaded &&
- !isFileHidden) {
+
+ if (widget.file.isUploaded && !isFileHidden) {
items.add(
EntePopupMenuItem(
- AppLocalizations.of(context).addToAlbum + "(i)",
+ AppLocalizations.of(context).addToAlbum,
value: 10,
icon: Icons.add,
iconColor: Theme.of(context).iconTheme.color,
diff --git a/mobile/apps/photos/lib/ui/viewer/file_details/albums_item_widget.dart b/mobile/apps/photos/lib/ui/viewer/file_details/albums_item_widget.dart
index 72a740f683..756534e502 100644
--- a/mobile/apps/photos/lib/ui/viewer/file_details/albums_item_widget.dart
+++ b/mobile/apps/photos/lib/ui/viewer/file_details/albums_item_widget.dart
@@ -106,22 +106,22 @@ class AlbumsItemWidget extends StatelessWidget {
}
// Add the '+' button if feature flag is enabled
- if (flagService.addToAlbumFeature) {
- chipButtons.add(
- ChipButtonWidget(
- "+ (i)",
- onTap: () {
- final selectedFiles = SelectedFiles();
- selectedFiles.files.add(file);
- showCollectionActionSheet(
- context,
- selectedFiles: selectedFiles,
- actionType: CollectionActionType.addFiles,
- );
- },
- ),
- );
- }
+ chipButtons.add(
+ ChipButtonWidget(
+ null,
+ leadingIcon: Icons.add,
+ iconSize: 15,
+ onTap: () {
+ final selectedFiles = SelectedFiles();
+ selectedFiles.files.add(file);
+ showCollectionActionSheet(
+ context,
+ selectedFiles: selectedFiles,
+ actionType: CollectionActionType.addFiles,
+ );
+ },
+ ),
+ );
return chipButtons;
} catch (e, s) {
diff --git a/mobile/apps/photos/lib/ui/viewer/gallery/gallery_app_bar_widget.dart b/mobile/apps/photos/lib/ui/viewer/gallery/gallery_app_bar_widget.dart
index e7cf0fc1ea..e4598bf94f 100644
--- a/mobile/apps/photos/lib/ui/viewer/gallery/gallery_app_bar_widget.dart
+++ b/mobile/apps/photos/lib/ui/viewer/gallery/gallery_app_bar_widget.dart
@@ -551,10 +551,9 @@ class _GalleryAppBarWidgetState extends State<GalleryAppBarWidget> {
? Icons.visibility_outlined
: Icons.visibility_off_outlined,
),
- // Gallery Guest View option - Internal user only
- if (flagService.albumGuestView && widget.collection != null)
+ if (widget.collection != null)
EntePopupMenuItem(
- AppLocalizations.of(context).guestView + " (i)",
+ AppLocalizations.of(context).guestView,
value: AlbumPopupAction.galleryGuestView,
iconWidget: SvgPicture.asset(
"assets/icons/guest_view_icon.svg",
@@ -705,8 +704,7 @@ class _GalleryAppBarWidgetState extends State<GalleryAppBarWidget> {
editLocation();
} else if (value == AlbumPopupAction.deleteLocation) {
await deleteLocation();
- } else if (value == AlbumPopupAction.galleryGuestView &&
- flagService.albumGuestView) {
+ } else if (value == AlbumPopupAction.galleryGuestView) {
await _onGalleryGuestViewClick();
} else {
showToast(context, AppLocalizations.of(context).somethingWentWrong);
@@ -1115,8 +1113,6 @@ class _GalleryAppBarWidgetState extends State<GalleryAppBarWidget> {
}
Future<void> _onGalleryGuestViewClick() async {
- if (!flagService.albumGuestView) return;
-
if (await LocalAuthentication().isDeviceSupported()) {
// Get all files from the collection with proper sort order
late final List<EnteFile> collectionFiles;
diff --git a/mobile/apps/photos/plugins/ente_feature_flag/lib/src/service.dart b/mobile/apps/photos/plugins/ente_feature_flag/lib/src/service.dart
index fc85347b30..4144ed5c0c 100644
--- a/mobile/apps/photos/plugins/ente_feature_flag/lib/src/service.dart
+++ b/mobile/apps/photos/plugins/ente_feature_flag/lib/src/service.dart
@@ -67,8 +67,6 @@ class FlagService {
bool get albumGuestView => internalUser;
bool get textDetection => internalUser && Platform.isIOS;
-
- bool get addToAlbumFeature => internalUser;
bool get widgetSharedAlbums => internalUser;