Smart WebView includes mechanisms to prompt users to rate your application on the relevant app store after certain usage conditions are met.


Enabling and Configuring

Configuration:

The prompt is enabled/disabled and configured using variables in `SmartWebView.java`. It uses the [Android-Rate](https://github.com/hotchemi/Android-Rate) library.
```java
// Enable the automatic app rating dialog prompt
static boolean ASWP_RATINGS = true;

// Minimum days after install before showing.
static int ASWR_DAYS = 3;
// Minimum number of app launches before showing.
static int ASWR_TIMES = 10;
// Days to wait before reminding if user selects "Later".
static int ASWR_INTERVAL = 2;
```
```md ```

How it Works

1. If `ASWP_RATINGS` is `true`, `MainActivity` schedules a check using `Functions.get_rating`. 2. `AppRate` library monitors install date and launch counts based on `ASWR_DAYS` and `ASWR_TIMES`. 3. `AppRate.showRateDialogIfMeetsConditions()` displays a dialog if conditions are met and the user hasn't permanently opted out. 4. Options: "Rate Now" (opens Play Store), "Remind Me Later" (waits `ASWR_INTERVAL` days), "No, Thanks" (disables future prompts). The dialog requires an internet connection. ```md ```

Customizing Dialog Text (Android)

Change the text displayed in the rating dialog via string resources in `app/src/main/res/values/strings.xml`: * `rate_dialog_title`, `rate_dialog_message` * `rate_dialog_ok` ("Rate Now"), `rate_dialog_cancel` ("Later"), `rate_dialog_no` ("No Thanks") ```md ```

Disabling the Rating Prompt

Set `ASWP_RATINGS` to `false` in `SmartWebView.java`. ```md ```