android 消息通知的方式
时间:2019-07-27 14:00:14
收藏:0
阅读:98
方式一,Toast,几秒后自动消失
Toast.makeText(this, "通知消息", Toast.LENGTH_SHORT).show();
方式二,AlertDialog,需要点击一下才能消失
AlertDialog.Builder builder = new AlertDialog.Builder(getContext());
builder.setMessage("通知消息");
builder.setTitle("提示");
builder.create().show();原文:https://www.cnblogs.com/liyanghui/p/11254748.html
评论(0)