首页 > 其他分享 >2022-11-16学习内容

2022-11-16学习内容

时间:2022-11-16 20:46:31浏览次数:42  
标签:11 xml 16 09 购物车 2022

1.案例-购物车-购物车列表展示

1.1item_cart.xml

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    xmlns:tools="http://schemas.android.com/tools"
    android:background="@color/white"
    android:orientation="horizontal">

    <ImageView
        android:id="@+id/iv_thumb"
        android:layout_width="85dp"
        android:layout_height="85dp"
        android:scaleType="fitCenter"
        tools:src="@drawable/xiaomi" />

    <LinearLayout
        android:layout_width="0dp"
        android:layout_height="match_parent"
        android:layout_weight="3"
        android:orientation="vertical">

        <TextView
            android:id="@+id/tv_name"
            android:layout_width="match_parent"
            android:layout_height="0dp"
            android:layout_weight="2"
            android:gravity="left|center"
            android:textColor="@color/black"
            android:textSize="17sp"
            tools:text="小米手机" />

        <TextView
            android:id="@+id/tv_desc"
            android:layout_width="match_parent"
            android:layout_height="0dp"
            android:layout_weight="3"
            android:gravity="left|center"
            android:textColor="@color/black"
            android:textSize="12sp"
            tools:text="小米 MI10 8GB+128GB 钛银黑 5G手机 游戏拍照手机" />
    </LinearLayout>

    <TextView
        android:id="@+id/tv_count"
        android:layout_width="0dp"
        android:layout_height="match_parent"
        android:layout_weight="1"
        android:gravity="center"
        android:textColor="@color/black"
        android:textSize="17sp"
        tools:text="2" />

    <TextView
        android:id="@+id/tv_price"
        android:layout_width="0dp"
        android:layout_height="match_parent"
        android:layout_weight="1"
        android:gravity="left|center"
        android:textColor="@color/black"
        android:textSize="15sp"
        tools:text="1000" />

    <TextView
        android:id="@+id/tv_sum"
        android:layout_width="0dp"
        android:layout_height="match_parent"
        android:layout_weight="1.2"
        android:gravity="right|center"
        android:textColor="@color/red"
        android:textSize="17sp"
        tools:text="2000" />

</LinearLayout>

进行到视频21:09。

标签:11,xml,16,09,购物车,2022
From: https://www.cnblogs.com/pingfanliliang/p/16894697.html

相关文章

  • SP11469 SUBSET - Balanced Cow Subsets Sol
    考虑枚举\(3^n\)种情况,用三进制数表示。对于每一位,\(0\)表示不放,\(1\)表示放入第一个集合,\(2\)表示放入第二个集合。这样显然会TLE。考虑meetinthemiddle。考......
  • 2022.11.17
    T1给你一个质数,让你求首先,观察到,答案很小(最大的大样例也只有\(16\)),于是就打了个质数表,跑了下最大的质数看看,答案最大也就是31,于是很明显,\(a\)的最大值就到31,一个很小......
  • 16.异常
    trycatchfinallythrow......
  • 2022_后台前端幕课网
    新建一个项目 vue3 命令 vuecreate****安装后发现版本低 可以使用以下指令升级版本,使支持最新setup语法[email protected]@[email protected]开发前期,......
  • LeetCode 110. 平衡二叉树
    给定一个二叉树,判断它是否是高度平衡的二叉树。本题中,一棵高度平衡二叉树定义为:一个二叉树每个节点 的左右两个子树的高度差的绝对值不超过1。classTreeNode:def__in......
  • 外键的知识-了解即可-2022-11-16
    1、外键----了解即可CreateTableCREATE TABLE `grade` (  `gradeid` int(10) NOT NULL COMMENT '年级id',  `gradename` varchar(50) NOT NULL ......
  • 2022.11.16 模拟赛总结
    2022.11.16模拟赛总结\(T1\)看起来对于我不是很可做,就大概看了一下\(50\)的做法,然后光速跳到\(T2\),\(T2\)打了个表把规律看出来了,然后又套了个组合意义,大概\(15m......
  • 闲话 22.11.16
    闲话今天给我整了个好活普通三维偏序的\(O(n\logn)\)解法那就要问了,形如\(a_i\lea_j,b_i\leb_j,d_j\lec_i\lec_j\)的加强版三维偏序有没有什么\(o(n\log^2n......
  • 【221116-2】已知三角形ABC中,角B=2α,角C=α,AB=18,AC=30.求三角形ABC的面积?
    2022年11月16日18点39分END......
  • 11.16 NOIP模拟赛
    A.长春花给定一个素数p,对每个0≤x<p,设f(x)表示一个最小的非负整数a,使得存在一个非负整数b,满足(a2+b2)modp=x。现在,你想要求max{f(0),f(1),⋯,f(p−1)}的值。......