private String[] areas = new String[]{"视频案例","图片案例"}; /** * 添加弹出窗口 * @author xmz * */ class AlertClickListener implements View.OnClickListener { @Override public void onClick(View v) { new AlertDialog.Builder(mContext).setTitle("").setItems(areas,new DialogInterface.OnClickListener(){ public void onClick(DialogInterface dialog, int which){ switch (which){ case 0: Intent intent0 = new Intent(mContext, AddCaseActivity.class); intent0.putExtra("isVideo",true); startActivityForResult(intent0, 1); break; case 1: Intent intent1 = new Intent(mContext, AddCaseActivity.class); intent1.putExtra("isVideo",false); startActivityForResult(intent1, 1); break; } dialog.dismiss(); } }).show(); }}
类似微型发朋友有圈时的弹出框
最新推荐文章于 2022-07-05 16:56:40 发布