I would like to implement swiping gesture from right to left for items inside RecyclerView. The view should be retained, so users can click on the delete button.
I found these approaches one, two, but I'm wondering if there are any newer or simpler ways.
Thanks for your help!
Related
in the beginning i want to apologize for my bad english but im currently working on an application, i have 2 firebase tables (propertys and tennants) sorted by the logged user (doesn't even matter for my problem). So i have 2 possibilities in the navigation drawer, i can add and view propertys, view is enabled in the recyclerview, adding is done by fab button, both RV and fab are in an fragment, same goes with tennants. I can click on each of items and view all the details about them in an activity, so what i want is when i click on an property item and it opens activity where my property details are, i have a button that should add tennats to that specific property and list them in that activity (property details). You guys got any solution? I tried onClick of that button to open tennants recyclerview and select multiple items and then onBackPressed to try to save them but i simply cannot get it working, then i tried with alertCustomDialog where it should list all the tennants (part that iam not able to do) and with checkboxes select tenants that i want to, please if anyone can help or has some clue how to do this, please HELP! :=)
I need to implement a swipe menu for each items in the recyclerview.I don't want to move the cell view according to the swipe action, instead I need to reveal the swipe layout. Can anyone help me out?
Try this library:
UltimateRecyclerView
https://github.com/cymcsg/UltimateRecyclerView
I'd like to implement a UI experience in Android where a user can view a single item (for example, an item in my case is a collection of texts), and swipe left or right on the item to go to the previous or next item.
From my research, ListView does not implement horizontal scrolling. Potential candidates seem to be HorizontalScrollView and GridView, but I haven't seen any examples that can do this simply - only seemingly complicated libraries that need to be included.
My question is, is there a way to use ListView, HorizontalScrollView, GridView, or a combination of them to implement a horizontal scroll that shows one item at a time and snaps to the item being displayed?
The highlighted area in the picture below shows where I'm trying to implement this logic.
It looks like the best option to achieve this experience is a ViewPager, which requires the android support library.
http://developer.android.com/reference/android/support/v4/view/ViewPager.html
i'm developing an application for android that is already done for IOS, is not big problem.
the thing is that my boss want it to be exactly the same, but one of the menus is the problem, is like a slide menu but with zoom and a background image, anyone have any idea how can i do this, i already google it but no results :(, a library would help.
here is a picture with the menu for IOS.
I don't think if it would be an effective solution but you can use a RelativeLayout.
Put the selection part behind in a LinearLayout then put a framelayout front to contain list fragments. This way you shouldn't use an action bar to have absolutely same looking with iOs version.
When someone clicks open button apply an animation to your framelayout. scale it by %75 and move it 25% in y coordinate and move it %50 in x coordinate. When buttons in your LinearLayout apply a reverse animation to your FrameLayout. If swap button clicked change your fragment with new one. You can also aply a transaction animation to your fragments.
I hope you know how to handle this stuff. If no I can do my best to code an example.
EDIT:
Don't forget to set your flame layout unclickable when you move it to right side.
https://github.com/SpecialCyCi/AndroidResideMenu
I think I found your answer. I came across this in a list of libraries it is 3.8 on the list https://github.com/Trinea/android-open-project/tree/master/English%20Version
Cheers!
at the moment i'm trying to write an app which has a listview, and if i swipe especially left the listitem switches to another xml like it's used in the twitter app.
Especially i have a list of items only with some text and when i swipe left on a single item it changes to an other item (via a xml-file) especially with some buttons or anything else.
I hope anyone, has an idea how i can do this?
Thanks.
I have seen this done using a Gallery set to fill_parent. Care has to be taken to allow child views to pass on touch events appropriately for swiping to work. Note that Gallery is a subclass of ViewGroup.
EDIT: see comment below, i should've checked the twitter app first!