x = (TextView)findViewById(R.id.xLink);
x.setOnTouchListener(new View.OnTouchListener() {
@Override
public boolean onTouch(View v, MotionEvent event) {
AlertDialog x = new AlertDialog.Builder(this.this).create();
x.setMessage(Html.fromHtml(getString(R.string.text)));
x.setButton(AlertDialog.BUTTON_NEUTRAL, "Ok", new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int which) {
dialog.dismiss();
}
});
x.show();
return false;
}
});
<TextView
android:id="@+id/xLink"
android:text="Click"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="@color/blue1"
android:paddingTop="30dip"
android:paddingRight="10dip"
android:layout_gravity="right"
android:textSize="16dip" />
<string name = "text">at<br /><a href="tel:18004455667">1-800-445-5667 lt;/a>.</string>
所以基本上當你點擊該鏈接一個對話框顯示了,在這似乎是一個鏈接,但是當你點擊,它什麼都不做數。這可能會發生什麼原因?我已經嘗試過改變瓦特/ ASCII字符,但什麼也沒做/電話號碼鏈接無法點擊的Android
也試過機器人:自動鏈接=「手機」,沒有做任何事情無論是 – user1823974