fix: 调整布局

This commit is contained in:
niushuai233 2022-10-17 15:09:35 +08:00
parent cbc75022cc
commit 61a1a7cac2
3 changed files with 5 additions and 4 deletions

View File

@ -57,7 +57,7 @@ public class NavDeviceFragment extends Fragment {
deviceGv.setSelector(new ColorDrawable(Color.TRANSPARENT));
List<HashMap<String, Object>> dataItem = new ArrayList<>();
for (int i = 0; i < 3; i++) {
for (int i = 0; i < 31; i++) {
HashMap<String, Object> m1 = new HashMap<>();
m1.put("device_item_cardView_image", R.drawable.ic_device_light_1);

View File

@ -10,7 +10,7 @@
android:id="@+id/main_nav_host_fragment_activity"
android:name="androidx.navigation.fragment.NavHostFragment"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_height="0dp"
app:defaultNavHost="true"
app:layout_constraintBottom_toTopOf="@id/bottom_nav_view"
app:layout_constraintHorizontal_bias="0.0"
@ -30,4 +30,4 @@
app:layout_constraintRight_toRightOf="parent"
app:menu="@menu/main_nav_menu" />
</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.constraintlayout.widget.ConstraintLayout>

View File

@ -20,7 +20,8 @@
<GridView
android:id="@id/device_gv"
android:paddingTop="25dp"
android:paddingTop="5dp"
android:paddingBottom="5dp"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:numColumns="2"