-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathAndroidAlertBuilderAndToast.java
More file actions
28 lines (27 loc) · 1.38 KB
/
AndroidAlertBuilderAndToast.java
File metadata and controls
28 lines (27 loc) · 1.38 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
/*
new AlertDialog.Builder (view.getContext()).setTitle("Attention")
.setMessage(msg)
.setNeutralButton("Close", null)
.show();
*/
///*
new AlertDialog.Builder(view.getContext()).setTitle("Confirm language change?")
.setMessage("Do you really what to change the APP language to "+str+"?")
.setPositiveButton("YES",
new DialogInterface.OnClickListener() {
public void onClick(DialogInterface dialog, int which) {
Log.i("Dialog yes", "Language change confirmed.");
dialog.dismiss();
}
})
.setNegativeButton("NO", new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int which) {
Log.i("Dialog yes", "Language change canceled.");
dialog.dismiss();
}
})
.create()
.show();
//*/
//Toast.makeText(view.getContext(), msg, Toast.LENGTH_LONG).show();