TextView startet Marquee neu, wenn ein anderes TextView in demselben LinearLayout geändert wird
Ich habe LinearLayout und in 2 TextView haben beide einen Auswahlrahmen und wenn ich Text im ersten und zweiten TextView aktualisiere, wird der Auswahlrahmen neu gestartet.
<LinearLayout
android:id="@+id/panel"
android:layout_width="320dp"
android:layout_height="match_parent"
android:layout_marginLeft="2dp"
android:layout_marginRight="2dp"
android:gravity="center_vertical"
android:orientation="vertical" >
<TextView
android:id="@+id/first"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:ellipsize="marquee"
android:gravity="bottom|center_horizontal"
android:marqueeRepeatLimit="marquee_forever"
android:singleLine="true" />
<TextView
android:id="@+id/second"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:ellipsize="marquee"
android:gravity="top|center_horizontal"
android:marqueeRepeatLimit="marquee_forever"
android:singleLine="true"
/>
</LinearLayout>
Ich fand das, wenn fürR.id.first
undR.id.second
ich setzelayout_width="320dp"
Der Effekt tritt nicht auf. Aber ich möchte einstellenandroid:layout_width="match_parent"
Gibt es eine Problemumgehung?
Ich habe ein ähnliches Problem gefunden, aber ohne Lösung:Android, RelativeLayout startet Marquee-TextView neu, wenn ImageView in demselben RelativeLayout geändert wird