Android工作整理-技术方案备份

1 屏幕适配
1.1:今日头条的适配方案,适配dp
https://blog.csdn.net/u013000152/article/details/80855315
注意:建议采用375dp,而不是750dp。因为会导致系统的弹窗宽高大小也跟着改变,例:采用750dp时,系统的复制粘贴会变小。

image.png

image.png

1.2:直接填写设计图上的像素尺寸,适配px
https://github.com/hongyangAndroid/AndroidAutoLayout

2 自定义toast
https://www.jianshu.com/p/4a37c61697dd

3 网络请求与gson解析
3.1 网络请求okhttp3 使用拦截器-interceptor可打印日志
https://www.jianshu.com/p/da4a806e599b
3.2 interceptor拦截器form表单请求参考
https://www.jianshu.com/p/3af806782a01?open_source=weibo_search
3.3 Gson-排除策略
https://blog.csdn.net/sunrainamazing/article/details/80975153
3.4 AndroidX迁移
https://blog.csdn.net/tuike/article/details/95937072
3.5 OkHttp常用详解
https://www.jianshu.com/p/aaa87e8ad9eb

4 Activity管理,包括退出登录
https://www.jianshu.com/p/6148aec5a7f5

5 状态栏
5.1 StatusBarUtil
https://github.com/laobie/StatusBarUtil
5.2 沉浸式状态栏
https://www.imooc.com/article/292777
5.3 状态栏适配 第三方
https://github.com/gyf-dev/ImmersionBar

6 首页
6.1 tab主界面
https://www.jianshu.com/p/e95a07330a89
6.2 加抽屉效果DrawerLayout
https://blog.csdn.net/yechaoa/article/details/91452474
手势开关
mDrawerLayout.setDrawerLockMode(DrawerLayout.LOCK_MODE_UNLOCKED); //打开手势滑动
mDrawerLayout.setDrawerLockMode(DrawerLayout.LOCK_MODE_LOCKED_CLOSED);

7 实现渐变+圆角+点击效果
https://blog.csdn.net/a1742226589/article/details/106133960

8 文本处理
8.1 TextView 中显示 HTML
https://zhuanlan.zhihu.com/p/27830863
8.2 超过两行显示成....
android:lines="2" android:ellipsize="end"
8.3 Android TextView部分文字实现点击事件
https://blog.csdn.net/mq2553299/article/details/78033581
8.4 ClickableSpan 去除下划线
https://blog.csdn.net/kk217777/article/details/51679707
8.5 设置字体样式正常,粗体,斜体,粗斜体
https://blog.csdn.net/qq_26420489/article/details/79931364
8.6 在java代码中设置TextView的字体大小,单位设为sp
https://blog.csdn.net/weixin_30878501/article/details/98195745
8.7 设置中粗
https://www.jianshu.com/p/849145cf1077
8.8 标签列表控件
https://github.com/donkingliang/LabelsView

9 倒计时CountDownTimer
https://www.jianshu.com/p/bb99a414c659

10 图片
10.1 glide加载网络图片、头像
https://blog.csdn.net/weixin_39654467/article/details/81043864
注意 Android 9.0开始 http请求默认失败。
临时方案清单配置文件追加:android:usesCleartextTraffic="true"
10.2 图片放大
https://github.com/iielse/ImageWatcher
10.3 圆角图片
implementation 'com.github.SheHuan:NiceImageView:1.0.5'

11 登录页按钮被键盘遮挡
https://www.cnblogs.com/taixiang/p/10091883.html

12 本地持久化存储,生成bean转json保存到SharedPreferences
https://www.jianshu.com/p/fffd1e6b9e55

13 一个可拖动的View
https://blog.csdn.net/user11223344abc/article/details/75805566

14 实现阴影效果
http://p.codekk.com/detail/5b0b7010fd1c9b26e2fcb529

15 Android 代码中如何将dp,sp转成px
https://blog.csdn.net/qq_35749683/article/details/84646708?utm_medium=distribute.pc_relevant.none-task-blog-BlogCommendFromMachineLearnPai2-3.compare&depth_1-utm_source=distribute.pc_relevant.none-task-blog-BlogCommendFromMachineLearnPai2-3.compare

16 一个支持多种状态的自定义View:加载中视图、错误视图、空数据视图、网络异常视图、内容视图
https://github.com/qyxxjd/MultipleStatusView

17 RecyclerView
17.1 第三方的RecyclerView Adapter
https://www.jianshu.com/p/b343fcff51b0
17.2 ScrollView嵌套RecyclerView滑动冲突解决(解决滑动边界有阴影问题android:overScrollMode="never")
https://www.jianshu.com/p/5dfc90656665
17.3 RecyclerView更新数据和定位到最底部
https://blog.csdn.net/flamejack/article/details/52004053?utm_medium=distribute.pc_relevant_t0.none-task-blog-BlogCommendFromMachineLearnPai2-1.nonecase&depth_1-utm_source=distribute.pc_relevant_t0.none-task-blog-BlogCommendFromMachineLearnPai2-1.nonecase
17.4 RecyclerView 监听滚动到底部
https://blog.csdn.net/qq_31387043/article/details/79863852

18 Dialog
18.1 底部Dialog弹窗
http://www.mamicode.com/info-detail-2026143.html
18.2 Dialog 宽度占满全屏
https://blog.csdn.net/b1480521874/article/details/87726091

19 进度条
19.1 Android 圆形进度条控件
https://www.jianshu.com/p/93d9a2a65bde
19.2 IndicatorSeekBar滑动显示进度气泡指示器
https://github.com/warkiz/IndicatorSeekBar
implementation 'com.github.warkiz.widget:indicatorseekbar:2.1.2'
//备用:https://github.com/Jay-Goo/RangeSeekBar
//备用:https://github.com/woxingxiao/BubbleSeekBar

19.2
https://www.jianshu.com/p/beb19f770e68

20 动画
20.1 Android5.0Activity的转场动画、过渡动画、过场动画、跳转动画
https://blog.csdn.net/w630886916/article/details/78319502
20.2 android5.0 水波纹点击效果
https://www.jianshu.com/p/7d2a8a5836e0
20.3 animateLayoutChanges布局内view状态改变动画
http://www.dovov.com/androidanimatelayoutchanges.html

21 Android----复制到剪切板
https://www.jianshu.com/p/1e84d33154bd

22 build.gradle配置
22.1 渠道与环境配置
https://www.jianshu.com/p/c11862136abf
22.2 打包名称规则
https://blog.csdn.net/u011272795/article/details/83991334

23 用CardView实现图片圆角
https://www.jianshu.com/p/17afa5997768
注意要设置app:cardBackgroundColor="#00000000",不然会有虚边

24 Android启动页出现白屏、黑屏的解决方案
https://www.jb51.net/article/130850.htm

25 MagicIndicator指示器
25.1 Android-指示器-MagicIndicator的使用
https://www.jianshu.com/p/af69d289e32c
25.2 MagicIndicator使用中遇到的坑
https://blog.csdn.net/qq_40837613/article/details/100058592

26 视频播放器
26.1 腾讯播放器-注意代码混淆
https://cloud.tencent.com/document/product/881/20213
26.2 用来测试的小视频地址集
https://www.jianshu.com/p/d5f00ad58572
26.3 VideoView 实现引导页播放视频欢迎效果
https://www.cnblogs.com/liguangsunls/p/7228377.html
26.4 录制视频
https://github.com/werbhelius/MediaUtils
26.5 使用Camera SurfaceView预览出现图案形变等问题解决总结
https://blog.csdn.net/u013597998/article/details/50437206
26.6 解决安卓10获取外部存储权限问题,导致播放本地视频文件错误。
https://blog.csdn.net/qin_peng123/article/details/109218665

27 语音识别-科大讯飞
https://www.xfyun.cn/doc/asr/voicedictation/Android-SDK.html#_1%E3%80%81%E7%AE%80%E4%BB%8B

28 显示Loading动画
https://blog.csdn.net/zhangphil/article/details/81943106

29 下拉刷新
https://github.com/scwang90/SmartRefreshLayout

30 Android:检测网络状态&监听网络变化
https://www.jianshu.com/p/983889116526

31 Android 时间工具DateUtil
https://blog.csdn.net/qq_16430735/article/details/49181669

32 EventBus 消息通信
https://github.com/greenrobot/EventBus

33 Android中保持屏幕常亮的方法:
https://www.cnblogs.com/sparrowlhl/p/11249004.html

34 [android获取状态栏高度为0的解决办法]
https://www.cnblogs.com/renkangke/archive/2013/05/27/3101375.html

35 第三方权限判断
35.1 XXPermissions
https://github.com/getActivity/XXPermissions
35.2 PermissionsDispatcher
https://github.com/permissions-dispatcher/PermissionsDispatcher
35.3 RxPermissions
https://github.com/tbruyelle/RxPermissions

36 java保留两位小数4种方法
https://www.cnblogs.com/Renyi-Fan/p/7643764.html

37 CoordinatorLayout流行效果
https://blog.csdn.net/m0_37667770/article/details/79900125

38 轮播图
https://github.com/youth5201314/banner
https://blog.csdn.net/zhenliang5553/article/details/81197407
implementation 'com.youth.banner:banner:1.4.10'

39 图表
https://github.com/PhilJay/MPAndroidChart
implementation 'com.github.PhilJay:MPAndroidChart:v3.1.0'

40 蓝牙工具
https://github.com/Jasonchenlijian/FastBle
implementation 'com.clj.fastble:FastBleLib:2.3.4'

你可能感兴趣的:(Android工作整理-技术方案备份)