Android-Rate
Android-Rate copied to clipboard
Custom events requirements for launching rate dialog
I came across a use case while using the api in my app. Basically, I wanted the rate dialog to launch only after the user has done some thing (click a button, visit a screen, etc.) 'n' times.
Does the api have anything of this sort? Would you be willing to allow something like this in the api?
Something like
AppRate.with(this) .setInstallDays(0) // default 10, 0 means install day. .setLaunchTimes(3) .setMinimumEventCount("buttonClick", 5) //"buttonClick" event has occured at lease 5 times ....
and a counter to increment the event count,
AppRate.incrementEventCount("buttonClick")
The developer could also add multiple events with different names this way to set non-trivial conditions.
Let me know if this sort of feature sounds useful to you. I can work on it for a weekend or 2 and raise a PR if you think it'll be valuable.
@ManojMadanmohan In https://github.com/Vorlonsoft/AndroidRate (Release 1.1.6+) you can use:
Optional custom event requirements for showing dialog
You can add additional optional requirements for showing dialog. Each requirement can be added/referenced as a unique string. You can set a minimum count for each such event (for e.g. "action_performed" 3 times, "button_clicked" 5 times, etc.)
AppRate.with(this).setMinimumEventCount(String, short);
AppRate.with(this).incrementEventCount(String);
AppRate.with(this).setEventCountValue(String, short);