解决LeftScrollView内容宽度设置问题,使用parent.getMeasuredWidth()解决。

This commit is contained in:
ZhanGSKen
2025-04-05 14:21:15 +08:00
parent 029d4193e1
commit 489bc87959
3 changed files with 20 additions and 15 deletions

View File

@@ -1,15 +1,17 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:padding="2dp">
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:padding="2dp"
android:id="@+id/linearLayout">
<cc.winboll.studio.positions.views.LeftScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/scrollView"/>
<cc.winboll.studio.positions.views.LeftScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/scrollView"/>
</LinearLayout>