I want to implement multi select gesture in my app like in new Google Photos App here:
I have tried following this answer, but couldn't do this. Can anyone just guide me?
Tap and hold the first photo of the album. Once you select it, you'll see a blue checkmark in its top-left corner. Scroll down to select other photos of the album, remember not to lift your finger from the screen while selecting. All selected photos will have a blue checkmark sign in the corner.
On Google Photos, the easiest way to grab a bunch of photos is to long press on one image until a blue check mark appears, but don't lift your finger off the screen. Then drag your finger across the photos you want to select, lifting it only when the job is done.
Apply the Same Edits to Multiple Shots If you've perfected edits on one image, apply them to a bunch of photos. On the desktop, while editing an image, go to the three-dot menu and select Copy edits. On the rest of the images, use the same menu to Paste Edits.
Check out this small project here: https://github.com/serzhby/MultiselectGridViewSample. It's far from perfect, but I think the idea of implementation should be clear. You should change the code for your particular need.
The main idea is to use GridView
class as a base class. By overriding the onTouchEvent
method we can detect which element was selected. Further processing is pretty staightforward.
Feel free to ask if you have any questions.
finally I found a library here. https://github.com/afollestad/drag-select-recyclerview.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With