安卓 我常用的库
1 2 3 4 5 6 7 8 | implementation 'androidx.appcompat:appcompat:1.1.0' implementation 'androidx.core:core-ktx:1.3.0' implementation 'androidx.constraintlayout:constraintlayout:1.1.3' implementation 'androidx.legacy:legacy-support-v4:1.0.0' implementation 'androidx.multidex:multidex:2.0.1' implementation 'androidx.multidex:multidex-instrumentation:2.0.0' androidTestImplementation 'androidx.test.ext:junit:1.1.1' androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' |
1 | implementation 'com.qmuiteam:qmui:2.0.0-alpha10' |
1 2 3 4 | //图片圆角 implementation 'com.makeramen:roundedimageview:2.3.0' //背景圆角 implementation 'com.flyco.roundview:FlycoRoundView_Lib:1.1.4@aar' |
1 | implementation 'com.github.GrenderG:Toasty:1.2.8' |
1 2 3 4 5 6 7 8 9 10 11 | private fun initToast() { Toasty.Config.getInstance() .setTextColor(ZJColor.white) .setWarningColor(ZJColor.black_tran) .setSuccessColor(ZJColor.black_tran) .setInfoColor(ZJColor.black_tran) .setErrorColor(ZJColor.black_tran) .setTextSize( 14 ) .setToastTypeface(Typeface.MONOSPACE) .apply() } |
dialog弹框
1 | implementation 'com.afollestad.material-dialogs:core:0.9.6.0' |
1 2 3 4 5 6 7 8 9 | MaterialDialog.Builder( this ) .title( "温馨提示" ) .theme(Theme.LIGHT) .content( "您确定要删除吗?" ) .positiveText( "确认" ) .negativeText( "取消" ) .onPositive { dialog, which -> } .show() |
1 2 3 4 5 6 7 8 9 10 11 12 | dialog = MaterialDialog.Builder( this ) .theme(Theme.LIGHT) .title( "加入群" ) .customView(R.layout.s_dialog_input, true ) .positiveText( "加入" ) .negativeText( "取消" ) .onPositive { dialog, which -> } .show() (dialog?.findViewById(R.id.input_edittext) as EditText).hint = "请输入要加入的群号" |
1 | implementation 'com.youth.banner:banner:2.0.11' |
1 2 | //Banner implementation 'cn.bingoogolapple:bga-banner:2.2.4@aar' |
仿ios
1 | implementation 'com.7heaven.widgets:segmentcontrol:1.17' |
加载HTML的TextView
1 2 3 | dependencies { implementation 'org.sufficientlysecure:html-textview:3.5' } |
1 2 3 4 5 6 | //# 必选,内部默认使用系统mediaplayer进行解码 implementation 'com.github.dueeeke.dkplayer:dkplayer-java:3.2.6' //# 可选,包含StandardVideoController的实现 implementation 'com.github.dueeeke.dkplayer:dkplayer-ui:3.2.6' //# 可选,使用exoplayer进行解码 implementation 'com.github.dueeeke.dkplayer:player-exo:3.2.6' |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | //网络请求 implementation 'io.reactivex.rxjava2:rxjava:2.1.10' implementation 'io.reactivex.rxjava2:rxandroid:2.0.2' implementation 'io.reactivex:rxandroid:1.2.1' implementation 'com.jakewharton.rxbinding2:rxbinding:2.1.1' implementation 'com.squareup.retrofit2:retrofit:2.6.0' implementation 'com.squareup.retrofit2:adapter-rxjava2:2.3.0' implementation 'com.squareup.okhttp3:logging-interceptor:4.0.1' implementation 'com.squareup.retrofit2:converter-gson:2.3.0' implementation 'com.trello.rxlifecycle2:rxlifecycle:2.2.1' implementation 'com.trello.rxlifecycle2:rxlifecycle-components:2.2.1' implementation 'com.trello.rxlifecycle2:rxlifecycle-android:2.2.1' //AutoDispose解决RxJava内存泄漏 implementation 'com.uber.autodispose:autodispose:0.7.0' implementation 'com.uber.autodispose:autodispose-android:0.7.0' implementation 'com.uber.autodispose:autodispose-android-archcomponents:0.7.0' |
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 基于Microsoft.Extensions.AI核心库实现RAG应用
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
· 开发者必知的日志记录最佳实践
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
· 无需6万激活码!GitHub神秘组织3小时极速复刻Manus,手把手教你使用OpenManus搭建本
· Manus爆火,是硬核还是营销?
· 终于写完轮子一部分:tcp代理 了,记录一下
· 别再用vector<bool>了!Google高级工程师:这可能是STL最大的设计失误
· 单元测试从入门到精通