android how to know when snackbar is done

Solutions on MaxInterview for android how to know when snackbar is done by the best coders in the world

we are a community of more than 2 million smartest coders
registration for
employee referral programs
are now open
get referred to google, amazon, flipkart and more
register now
  
pinned-register now
showing results for - "android how to know when snackbar is done"
Camille
03 Jan 2019
1snackbar.addCallback(new Snackbar.Callback() {
2
3    @Override
4    public void onDismissed(Snackbar snackbar, int event) {
5        if (event == Snackbar.Callback.DISMISS_EVENT_TIMEOUT) {
6            // Snackbar closed on its own
7        }
8    }
9
10    @Override
11    public void onShown(Snackbar snackbar) {
12        ...
13    }
14});