-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAlertDialog.java
More file actions
18 lines (17 loc) · 970 Bytes
/
AlertDialog.java
File metadata and controls
18 lines (17 loc) · 970 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
private void launchAlertDialog() {
new MaterialAlertDialogBuilder(AlertDialog.this, R.style.MaterialAlertDialog_Rounded)
.setTitle("Quity update required")
.setMessage("Quity recommends that you to update to latest version")
.setPositiveButton("Update", new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int i) {
try {
startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("https://play.google.com/store/apps/details?id=com.anuhas.quity")));
}catch (Exception e){
startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("https://play.google.com/store/apps/details?id=com.anuhas.quity")));
}
}
})
.setCancelable(false)
.show();
}