1 |
torben |
245 |
package dk.thoerup.traininfo.util;
|
2 |
|
|
|
3 |
|
|
import android.app.AlertDialog;
|
4 |
|
|
import android.content.Context;
|
5 |
|
|
import android.content.DialogInterface;
|
6 |
|
|
|
7 |
|
|
public class MessageBox {
|
8 |
|
|
|
9 |
|
|
public static void showMessage(Context cntx, String message) {
|
10 |
|
|
AlertDialog.Builder builder = new AlertDialog.Builder(cntx);
|
11 |
|
|
builder.setMessage(message)
|
12 |
|
|
.setCancelable(false)
|
13 |
|
|
.setPositiveButton("OK", new DialogInterface.OnClickListener() {
|
14 |
|
|
public void onClick(DialogInterface dialog, int id) {
|
15 |
|
|
dialog.dismiss();
|
16 |
|
|
}
|
17 |
|
|
})
|
18 |
|
|
.show();
|
19 |
|
|
|
20 |
|
|
}
|
21 |
|
|
}
|