diff options
author | Stefan Niedermann <info@niedermann.it> | 2020-11-04 17:31:40 +0300 |
---|---|---|
committer | Stefan Niedermann <info@niedermann.it> | 2020-11-04 17:31:40 +0300 |
commit | de0c0f2b29b6e8deb99d5c793490967ca90eecfb (patch) | |
tree | 904bc6d6e460b03cd74ce056e33364abc0050bc5 /app/src/main/java/it/niedermann/nextcloud/deck/ui/card/attachments/picker/GalleryAdapter.java | |
parent | 1ab635e7ab3e103230f78aa96bc715218a78c4f4 (diff) |
Small refactorings
Signed-off-by: Stefan Niedermann <info@niedermann.it>
Diffstat (limited to 'app/src/main/java/it/niedermann/nextcloud/deck/ui/card/attachments/picker/GalleryAdapter.java')
-rw-r--r-- | app/src/main/java/it/niedermann/nextcloud/deck/ui/card/attachments/picker/GalleryAdapter.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/src/main/java/it/niedermann/nextcloud/deck/ui/card/attachments/picker/GalleryAdapter.java b/app/src/main/java/it/niedermann/nextcloud/deck/ui/card/attachments/picker/GalleryAdapter.java index 209e4af90..b7f76f3d3 100644 --- a/app/src/main/java/it/niedermann/nextcloud/deck/ui/card/attachments/picker/GalleryAdapter.java +++ b/app/src/main/java/it/niedermann/nextcloud/deck/ui/card/attachments/picker/GalleryAdapter.java @@ -41,8 +41,8 @@ public class GalleryAdapter extends AbstractPickerAdapter<RecyclerView.ViewHolde ? MediaStore.Images.Media.DATE_TAKEN : MediaStore.Images.Media.DATE_ADDED; - public GalleryAdapter(@NonNull Context context, @NonNull Consumer<Uri> onSelect, @NonNull Runnable onSelectPicker, @NonNull LifecycleOwner lifecycleOwner) { - super(context, onSelect, onSelectPicker, EXTERNAL_CONTENT_URI, _ID, sortOrder + " DESC"); + public GalleryAdapter(@NonNull Context context, @NonNull Consumer<Uri> onSelect, @NonNull Runnable openNativePicker, @NonNull LifecycleOwner lifecycleOwner) { + super(context, onSelect, openNativePicker, EXTERNAL_CONTENT_URI, _ID, sortOrder + " DESC"); this.lifecycleOwner = lifecycleOwner; notifyItemRangeInserted(0, getItemCount()); } @@ -65,7 +65,7 @@ public class GalleryAdapter extends AbstractPickerAdapter<RecyclerView.ViewHolde public void onBindViewHolder(@NonNull RecyclerView.ViewHolder holder, int position) { switch (getItemViewType(position)) { case VIEW_TYPE_ITEM_PICKER: { - ((GalleryPickerItemViewHolder) holder).bind(onSelectPicker, lifecycleOwner); + ((GalleryPickerItemViewHolder) holder).bind(openNativePicker, lifecycleOwner); break; } case VIEW_TYPE_ITEM: { |