Commit 78e994b709538e3dc1ff1ac7e87541307163e4ca
1 parent
8704fec5
1 二维码邀请适配小屏幕
Showing
3 changed files
with
156 additions
and
154 deletions
config.gradle
module_xiaojiaSoundBox/src/main/java/com/cnlive/strike/xiaojiaspeaker/ui/activity/RemoteControlActivity.java
| @@ -199,7 +199,6 @@ public class RemoteControlActivity extends AppCompatActivity { | @@ -199,7 +199,6 @@ public class RemoteControlActivity extends AppCompatActivity { | ||
| 199 | .setSuccessCallback(new SuccessCallback<APIBaseInfo>() { | 199 | .setSuccessCallback(new SuccessCallback<APIBaseInfo>() { |
| 200 | @Override | 200 | @Override |
| 201 | public void onSuccess(APIBaseInfo baseInfo) { | 201 | public void onSuccess(APIBaseInfo baseInfo) { |
| 202 | - Log.e(TAG, "onSuccess: "); | ||
| 203 | if (null == binding) { | 202 | if (null == binding) { |
| 204 | return; | 203 | return; |
| 205 | } | 204 | } |
module_xiaojiaSoundBox/src/main/res/layout/fragment_invit_friend.xml
| @@ -16,187 +16,190 @@ | @@ -16,187 +16,190 @@ | ||
| 16 | android:layout_width="match_parent" | 16 | android:layout_width="match_parent" |
| 17 | android:layout_height="match_parent"> | 17 | android:layout_height="match_parent"> |
| 18 | 18 | ||
| 19 | - <LinearLayout | 19 | + <ScrollView |
| 20 | android:layout_width="match_parent" | 20 | android:layout_width="match_parent" |
| 21 | - android:layout_height="match_parent" | ||
| 22 | - android:orientation="vertical"> | ||
| 23 | - | 21 | + android:layout_height="match_parent"> |
| 24 | 22 | ||
| 25 | - <!--1--> | ||
| 26 | <LinearLayout | 23 | <LinearLayout |
| 27 | android:layout_width="match_parent" | 24 | android:layout_width="match_parent" |
| 28 | - android:layout_height="wrap_content" | 25 | + android:layout_height="match_parent" |
| 29 | android:orientation="vertical"> | 26 | android:orientation="vertical"> |
| 30 | - | ||
| 31 | - <TextView | ||
| 32 | - android:layout_width="wrap_content" | ||
| 33 | - android:layout_height="wrap_content" | ||
| 34 | - android:layout_marginLeft="10dp" | ||
| 35 | - android:layout_marginTop="10dp" | ||
| 36 | - android:text="选择家人角色" | ||
| 37 | - android:textColor="@color/color_282828" | ||
| 38 | - android:textSize="16sp" | ||
| 39 | - android:textStyle="bold" /> | ||
| 40 | - | ||
| 41 | - <android.support.v7.widget.RecyclerView | ||
| 42 | - android:id="@+id/rv_role" | 27 | + <!--1--> |
| 28 | + <LinearLayout | ||
| 43 | android:layout_width="match_parent" | 29 | android:layout_width="match_parent" |
| 44 | android:layout_height="wrap_content" | 30 | android:layout_height="wrap_content" |
| 45 | - android:minHeight="40dp" | ||
| 46 | - android:overScrollMode="never" /> | ||
| 47 | - </LinearLayout> | ||
| 48 | - <!--2--> | ||
| 49 | - <LinearLayout | ||
| 50 | - android:layout_width="match_parent" | ||
| 51 | - android:layout_height="0dp" | ||
| 52 | - android:layout_weight="1" | ||
| 53 | - android:gravity="center" | ||
| 54 | - android:orientation="vertical"> | 31 | + android:orientation="vertical"> |
| 32 | + | ||
| 33 | + <TextView | ||
| 34 | + android:layout_width="wrap_content" | ||
| 35 | + android:layout_height="wrap_content" | ||
| 36 | + android:layout_marginLeft="10dp" | ||
| 37 | + android:layout_marginTop="10dp" | ||
| 38 | + android:text="选择家人角色" | ||
| 39 | + android:textColor="@color/color_282828" | ||
| 40 | + android:textSize="16sp" | ||
| 41 | + android:textStyle="bold" /> | ||
| 55 | 42 | ||
| 56 | - <FrameLayout | ||
| 57 | - android:layout_width="wrap_content" | 43 | + <android.support.v7.widget.RecyclerView |
| 44 | + android:id="@+id/rv_role" | ||
| 45 | + android:layout_width="match_parent" | ||
| 46 | + android:layout_height="wrap_content" | ||
| 47 | + android:minHeight="40dp" | ||
| 48 | + android:overScrollMode="never" /> | ||
| 49 | + </LinearLayout> | ||
| 50 | + <!--2--> | ||
| 51 | + <LinearLayout | ||
| 52 | + android:layout_width="match_parent" | ||
| 58 | android:layout_height="wrap_content" | 53 | android:layout_height="wrap_content" |
| 59 | - android:layout_gravity="center_horizontal" | ||
| 60 | - android:padding="5dp" | ||
| 61 | - android:background="@drawable/bg_xiaojia_qrcode"> | 54 | + android:layout_weight="1" |
| 55 | + android:gravity="center" | ||
| 56 | + android:orientation="vertical"> | ||
| 62 | 57 | ||
| 63 | <FrameLayout | 58 | <FrameLayout |
| 64 | android:layout_width="wrap_content" | 59 | android:layout_width="wrap_content" |
| 65 | - android:layout_height="wrap_content"> | ||
| 66 | - | ||
| 67 | - <ImageView | ||
| 68 | - android:id="@+id/iv_qrcode" | ||
| 69 | - android:layout_width="220dp" | ||
| 70 | - android:layout_height="220dp" /> | ||
| 71 | - | ||
| 72 | - <LinearLayout | ||
| 73 | - android:id="@+id/ll_no_qrcode" | ||
| 74 | - android:layout_width="220dp" | ||
| 75 | - android:layout_height="220dp" | ||
| 76 | - android:background="#E1F9D7" | ||
| 77 | - android:gravity="center" | ||
| 78 | - android:orientation="vertical"> | ||
| 79 | - | ||
| 80 | - <TextView | ||
| 81 | - android:layout_width="wrap_content" | ||
| 82 | - android:layout_height="wrap_content" | ||
| 83 | - android:text="选择家人角色" | ||
| 84 | - android:textColor="@color/color_199F18" | ||
| 85 | - android:textSize="18sp" | ||
| 86 | - android:textStyle="bold" /> | ||
| 87 | - | ||
| 88 | - <TextView | ||
| 89 | - android:layout_width="wrap_content" | ||
| 90 | - android:layout_height="wrap_content" | ||
| 91 | - android:layout_marginTop="20dp" | ||
| 92 | - android:text="生成二维码" | ||
| 93 | - android:textColor="@color/color_199F18" | ||
| 94 | - android:textSize="18sp" | ||
| 95 | - android:textStyle="bold" /> | ||
| 96 | - </LinearLayout> | 60 | + android:layout_height="wrap_content" |
| 61 | + android:layout_gravity="center_horizontal" | ||
| 62 | + android:background="@drawable/bg_xiaojia_qrcode" | ||
| 63 | + android:padding="5dp"> | ||
| 64 | + | ||
| 65 | + <FrameLayout | ||
| 66 | + android:layout_width="wrap_content" | ||
| 67 | + android:layout_height="wrap_content"> | ||
| 68 | + | ||
| 69 | + <ImageView | ||
| 70 | + android:id="@+id/iv_qrcode" | ||
| 71 | + android:layout_width="220dp" | ||
| 72 | + android:layout_height="220dp" /> | ||
| 73 | + | ||
| 74 | + <LinearLayout | ||
| 75 | + android:id="@+id/ll_no_qrcode" | ||
| 76 | + android:layout_width="220dp" | ||
| 77 | + android:layout_height="220dp" | ||
| 78 | + android:background="#E1F9D7" | ||
| 79 | + android:gravity="center" | ||
| 80 | + android:orientation="vertical"> | ||
| 81 | + | ||
| 82 | + <TextView | ||
| 83 | + android:layout_width="wrap_content" | ||
| 84 | + android:layout_height="wrap_content" | ||
| 85 | + android:text="选择家人角色" | ||
| 86 | + android:textColor="@color/color_199F18" | ||
| 87 | + android:textSize="18sp" | ||
| 88 | + android:textStyle="bold" /> | ||
| 89 | + | ||
| 90 | + <TextView | ||
| 91 | + android:layout_width="wrap_content" | ||
| 92 | + android:layout_height="wrap_content" | ||
| 93 | + android:layout_marginTop="20dp" | ||
| 94 | + android:text="生成二维码" | ||
| 95 | + android:textColor="@color/color_199F18" | ||
| 96 | + android:textSize="18sp" | ||
| 97 | + android:textStyle="bold" /> | ||
| 98 | + </LinearLayout> | ||
| 99 | + </FrameLayout> | ||
| 97 | </FrameLayout> | 100 | </FrameLayout> |
| 98 | - </FrameLayout> | ||
| 99 | - </LinearLayout> | ||
| 100 | - <!--3--> | ||
| 101 | - <LinearLayout | ||
| 102 | - android:layout_width="match_parent" | ||
| 103 | - android:layout_height="0dp" | ||
| 104 | - android:layout_weight="1" | ||
| 105 | - android:gravity="center" | ||
| 106 | - android:orientation="vertical"> | ||
| 107 | - | ||
| 108 | - <TextView | ||
| 109 | - android:layout_width="wrap_content" | ||
| 110 | - android:layout_height="wrap_content" | ||
| 111 | - android:layout_gravity="center_horizontal" | ||
| 112 | - android:layout_marginTop="20dp" | ||
| 113 | - android:text="请对方使用网家家“扫一扫”绑定" | ||
| 114 | - android:textColor="@color/color_282828" | ||
| 115 | - android:textSize="18sp" | ||
| 116 | - android:textStyle="bold" /> | ||
| 117 | - | 101 | + </LinearLayout> |
| 102 | + <!--3--> | ||
| 118 | <LinearLayout | 103 | <LinearLayout |
| 119 | android:layout_width="match_parent" | 104 | android:layout_width="match_parent" |
| 120 | android:layout_height="wrap_content" | 105 | android:layout_height="wrap_content" |
| 121 | - android:layout_marginTop="20dp" | ||
| 122 | - android:gravity="center"> | ||
| 123 | - | ||
| 124 | - <TextView | ||
| 125 | - android:layout_width="15dp" | ||
| 126 | - android:layout_height="15dp" | ||
| 127 | - android:background="@drawable/shape_xiaojia_green_circle" | ||
| 128 | - android:gravity="center" | ||
| 129 | - android:text="1" | ||
| 130 | - android:textColor="@color/white" | ||
| 131 | - android:textSize="11sp" | ||
| 132 | - android:textStyle="bold" /> | 106 | + android:layout_weight="1" |
| 107 | + android:gravity="center" | ||
| 108 | + android:orientation="vertical"> | ||
| 133 | 109 | ||
| 134 | <TextView | 110 | <TextView |
| 135 | android:layout_width="wrap_content" | 111 | android:layout_width="wrap_content" |
| 136 | android:layout_height="wrap_content" | 112 | android:layout_height="wrap_content" |
| 137 | - android:layout_marginLeft="5dp" | ||
| 138 | - android:layout_marginRight="5dp" | ||
| 139 | - android:text="下载网家家 >" | 113 | + android:layout_gravity="center_horizontal" |
| 114 | + android:layout_marginTop="20dp" | ||
| 115 | + android:text="请对方使用网家家“扫一扫”绑定" | ||
| 140 | android:textColor="@color/color_282828" | 116 | android:textColor="@color/color_282828" |
| 141 | - android:textSize="12sp" | 117 | + android:textSize="18sp" |
| 142 | android:textStyle="bold" /> | 118 | android:textStyle="bold" /> |
| 143 | 119 | ||
| 144 | - <TextView | ||
| 145 | - android:layout_width="15dp" | ||
| 146 | - android:layout_height="15dp" | ||
| 147 | - android:background="@drawable/shape_xiaojia_green_circle" | ||
| 148 | - android:gravity="center" | ||
| 149 | - android:text="2" | ||
| 150 | - android:textColor="@color/white" | ||
| 151 | - android:textSize="11sp" | ||
| 152 | - android:textStyle="bold" /> | ||
| 153 | - | ||
| 154 | - <TextView | ||
| 155 | - android:layout_width="wrap_content" | 120 | + <LinearLayout |
| 121 | + android:layout_width="match_parent" | ||
| 156 | android:layout_height="wrap_content" | 122 | android:layout_height="wrap_content" |
| 157 | - android:layout_marginLeft="5dp" | ||
| 158 | - android:layout_marginRight="5dp" | ||
| 159 | - android:text="注册/登录 >" | ||
| 160 | - android:textColor="@color/color_282828" | ||
| 161 | - android:textSize="12sp" | ||
| 162 | - android:textStyle="bold" /> | 123 | + android:layout_marginTop="20dp" |
| 124 | + android:gravity="center"> | ||
| 163 | 125 | ||
| 164 | - <TextView | ||
| 165 | - android:layout_width="15dp" | ||
| 166 | - android:layout_height="15dp" | ||
| 167 | - android:background="@drawable/shape_xiaojia_green_circle" | ||
| 168 | - android:gravity="center" | ||
| 169 | - android:text="3" | 126 | + <TextView |
| 127 | + android:layout_width="15dp" | ||
| 128 | + android:layout_height="15dp" | ||
| 129 | + android:background="@drawable/shape_xiaojia_green_circle" | ||
| 130 | + android:gravity="center" | ||
| 131 | + android:text="1" | ||
| 132 | + android:textColor="@color/white" | ||
| 133 | + android:textSize="11sp" | ||
| 134 | + android:textStyle="bold" /> | ||
| 135 | + | ||
| 136 | + <TextView | ||
| 137 | + android:layout_width="wrap_content" | ||
| 138 | + android:layout_height="wrap_content" | ||
| 139 | + android:layout_marginLeft="5dp" | ||
| 140 | + android:layout_marginRight="5dp" | ||
| 141 | + android:text="下载网家家 >" | ||
| 142 | + android:textColor="@color/color_282828" | ||
| 143 | + android:textSize="12sp" | ||
| 144 | + android:textStyle="bold" /> | ||
| 145 | + | ||
| 146 | + <TextView | ||
| 147 | + android:layout_width="15dp" | ||
| 148 | + android:layout_height="15dp" | ||
| 149 | + android:background="@drawable/shape_xiaojia_green_circle" | ||
| 150 | + android:gravity="center" | ||
| 151 | + android:text="2" | ||
| 152 | + android:textColor="@color/white" | ||
| 153 | + android:textSize="11sp" | ||
| 154 | + android:textStyle="bold" /> | ||
| 155 | + | ||
| 156 | + <TextView | ||
| 157 | + android:layout_width="wrap_content" | ||
| 158 | + android:layout_height="wrap_content" | ||
| 159 | + android:layout_marginLeft="5dp" | ||
| 160 | + android:layout_marginRight="5dp" | ||
| 161 | + android:text="注册/登录 >" | ||
| 162 | + android:textColor="@color/color_282828" | ||
| 163 | + android:textSize="12sp" | ||
| 164 | + android:textStyle="bold" /> | ||
| 165 | + | ||
| 166 | + <TextView | ||
| 167 | + android:layout_width="15dp" | ||
| 168 | + android:layout_height="15dp" | ||
| 169 | + android:background="@drawable/shape_xiaojia_green_circle" | ||
| 170 | + android:gravity="center" | ||
| 171 | + android:text="3" | ||
| 172 | + android:textColor="@color/white" | ||
| 173 | + android:textSize="11sp" | ||
| 174 | + android:textStyle="bold" /> | ||
| 175 | + | ||
| 176 | + <TextView | ||
| 177 | + android:layout_width="wrap_content" | ||
| 178 | + android:layout_height="wrap_content" | ||
| 179 | + android:layout_marginLeft="5dp" | ||
| 180 | + android:text="扫码绑定" | ||
| 181 | + android:textColor="@color/color_282828" | ||
| 182 | + android:textSize="12sp" | ||
| 183 | + android:textStyle="bold" /> | ||
| 184 | + </LinearLayout> | ||
| 185 | + <!-- --> | ||
| 186 | + <Button | ||
| 187 | + android:id="@+id/btn_share" | ||
| 188 | + android:layout_width="match_parent" | ||
| 189 | + android:layout_height="40dp" | ||
| 190 | + android:layout_alignParentBottom="true" | ||
| 191 | + android:layout_centerHorizontal="true" | ||
| 192 | + android:layout_marginLeft="20dp" | ||
| 193 | + android:layout_marginTop="30dp" | ||
| 194 | + android:layout_marginRight="20dp" | ||
| 195 | + android:background="@drawable/selector_xiaojia_btn_green" | ||
| 196 | + android:text="保存并分享给家人" | ||
| 170 | android:textColor="@color/white" | 197 | android:textColor="@color/white" |
| 171 | - android:textSize="11sp" | ||
| 172 | - android:textStyle="bold" /> | ||
| 173 | - | ||
| 174 | - <TextView | ||
| 175 | - android:layout_width="wrap_content" | ||
| 176 | - android:layout_height="wrap_content" | ||
| 177 | - android:layout_marginLeft="5dp" | ||
| 178 | - android:text="扫码绑定" | ||
| 179 | - android:textColor="@color/color_282828" | ||
| 180 | - android:textSize="12sp" | 198 | + android:textSize="16sp" |
| 181 | android:textStyle="bold" /> | 199 | android:textStyle="bold" /> |
| 182 | </LinearLayout> | 200 | </LinearLayout> |
| 183 | - <!-- --> | ||
| 184 | - <Button | ||
| 185 | - android:id="@+id/btn_share" | ||
| 186 | - android:layout_width="match_parent" | ||
| 187 | - android:layout_height="40dp" | ||
| 188 | - android:layout_alignParentBottom="true" | ||
| 189 | - android:layout_centerHorizontal="true" | ||
| 190 | - android:layout_marginLeft="20dp" | ||
| 191 | - android:layout_marginTop="30dp" | ||
| 192 | - android:layout_marginRight="20dp" | ||
| 193 | - android:background="@drawable/selector_xiaojia_btn_green" | ||
| 194 | - android:text="保存并分享给家人" | ||
| 195 | - android:textColor="@color/white" | ||
| 196 | - android:textSize="16sp" | ||
| 197 | - android:textStyle="bold" /> | ||
| 198 | </LinearLayout> | 201 | </LinearLayout> |
| 199 | - </LinearLayout> | 202 | + </ScrollView> |
| 200 | 203 | ||
| 201 | <com.cnlive.strike.ui.widget.UIEmptyView | 204 | <com.cnlive.strike.ui.widget.UIEmptyView |
| 202 | android:id="@+id/empty_layout" | 205 | android:id="@+id/empty_layout" |