Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Swipe events for SwipeDrawer behaviour #940

Merged
merged 6 commits into from
Nov 9, 2020
Merged

Swipe events for SwipeDrawer behaviour #940

merged 6 commits into from
Nov 9, 2020

Conversation

RobbWatershed
Copy link
Contributor

Add an optional callback interface to SimpleSwipeDrawerCallback

  • SimpleSwipeDrawerCallback.ItemSwipeCallback.itemSwiped : Called when a drawer has been swiped (same bahaviour as SimpleSwipeCallback.ItemSwipeCallback.itemSwiped)

  • SimpleSwipeDrawerCallback.ItemSwipeCallback.itemUnswiped : Called when a drawer has been un-swiped (= returns to its default position)

  • update SwipeDrawerListActivity to log these events.

Comment on lines 96 to 97
viewHolder.itemView.translationX = 0f
viewHolder.itemView.translationY = 0f
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you please describe why we need to reset the translation for this change?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're right, we don't need that. I just did a blind copy/paste from SimpleSwipeCallback. My mistake

@RobbWatershed
Copy link
Contributor Author

Maybe I'm asking too much, but would it be possible to have these changes into a new release when you find the time to do so ?

Thanks a bunch 🌞

@mikepenz
Copy link
Owner

mikepenz commented Nov 9, 2020

@RobbWatershed oh. I am sorry that I haven't already done so.

@mikepenz mikepenz merged commit e0c4502 into mikepenz:develop Nov 9, 2020
@RobbWatershed
Copy link
Contributor Author

@RobbWatershed oh. I am sorry that I haven't already done so.

No worries. Thank you !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants