調用調用撥號器
一、邏輯代碼
//我們需要告訴系統,我們的動作:我要打電話
//創建意圖對象
Intent intent = new Intent();
//把動作封裝至意圖對象當中
intent.setAction(Intent.ACTION_CALL);
//設置打給誰
intent.setData(Uri.parse("tel:" + phone));
//把動作告訴系統
startActivity(intent);
二、權限
<uses-permission android:name="android.permission.CALL_PHONE"/>