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

How to check if menu has closed? #8

Open
Bekakk opened this issue Sep 19, 2017 · 0 comments
Open

How to check if menu has closed? #8

Bekakk opened this issue Sep 19, 2017 · 0 comments

Comments

@Bekakk
Copy link

Bekakk commented Sep 19, 2017

Hi
I'm using your repository and I have one question.
Is it a possible to check when menu closed.Here is a your method,whitch does not has static duration

` public void smoothScrollContentTo(int targetOffset, float velocity) {
setCurrentState(STATE_SCROLL);
int distance = targetOffset - mCurrentContentOffset;
velocity = Math.abs(velocity);
int duration = 400;
if (velocity > 0) {
duration = 3 * Math.round(1000 * Math.abs(distance / velocity));
}
duration = Math.min(duration, MAX_DURATION);
mScroller.abortAnimation();
mScroller.startScroll(mCurrentContentOffset, 0, distance, 0, duration);
invalidate();
}

Simple
I want to call my function,when menu has closed successfully
Thanks`

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

No branches or pull requests

1 participant