我有这个布局
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:ads="http://schemas.android.com/apk/res-auto"
android:id="@+id/RelativeLayout1"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#fff" >
<TabHost
android:id="@+id/tabhost"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@+id/adView" >
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<TabWidget
android:id="@android:id/tabs"
android:layout_width="match_parent"
android:layout_height="wrap_content" >
</TabWidget>
<TextView
android:id="@+id/title"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:text="@string/app_name"
android:textAppearance="?android:attr/textAppearanceLarge" />
<FrameLayout
android:id="@android:id/tabcontent"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_margin="20dp" >
<LinearLayout
android:id="@+id/order_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<ImageView
android:id="@+id/logoImage"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:src="@drawable/logo" />
<TextView
android:id="@+id/order_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="10dp"
android:layout_weight="1"
android:autoLink="phone"
android:clickable="true"
android:gravity="center_horizontal"
android:text="@string/order"
android:textSize="18sp" />
</LinearLayout>
<LinearLayout
android:id="@+id/about_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<TextView
android:id="@+id/about_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center"
android:autoLink="all"
android:scrollbars="vertical"
android:text="@string/about" />
</LinearLayout>
<LinearLayout
android:id="@+id/tarrifs_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<TextView
android:id="@+id/tarrifs_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center"
android:autoLink="all"
android:scrollbars="vertical"
android:text="@string/tarrifs" />
</LinearLayout>
</FrameLayout>
</LinearLayout>
</TabHost>
<com.google.android.gms.ads.AdView
android:id="@+id/adView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_alignParentBottom="true"
ads:adSize="SMART_BANNER"
ads:adUnitId="@string/admob_id" >
</com.google.android.gms.ads.AdView>
</RelativeLayout>
在textview order_content中我把字符串: &#34; \ r \ n 11-22-33 8 999 333 11 22 \ r \ n 8 888 444 22 33 \ r \ n &#34; 两个电话号码除了第一个是彩色的(蓝色和下划线),但我无法点击它们并打电话,有人可以帮我吗? 附:对不起我的英文
解决 - 评论行:tv_order.setMovementMethod(new ScrollingMovementMethod());
答案 0 :(得分:0)
问题行:tv_order.setMovementMethod(new ScrollingMovementMethod());