Tapadoo / Alerter

An Android Alerting Library
MIT License
5.52k stars 633 forks source link

Add onHideListener to hide() & clearCurrent() methods #260

Closed jassielcastro closed 3 years ago

jassielcastro commented 3 years ago

This PR allows to add the OnHideListener listener in a separate way to the current one when creating an Alerter

//Current code
Alerter.crete(activity)
    .setOnHideListener(listener)
    .show()

And this is a new proposal for the different possibilities of closing Alerter outside of its creation.

//Current code
Alerter.crete(activity)
    .show()

---
//New options to hide the Alerter with a listener
Alerter.hide {
   doSomething()
}

Alerter.clearCurrent(activity) {
    doSomething()   
}
kpmmmurphy commented 3 years ago

That's super @jassielcastro, thanks for adding this! Looks all good from a code perspective. Please bump the version to 7.2.0 in the build.gradle file, and update the changelog - then we can get this merged 🚀

jassielcastro commented 3 years ago

@kpmmmurphy Done! Let me know if I can help with anything else!