Anko对话框按钮标题
与安科我可以写这样的东西显示对话框:
alert("Dialog title") { yesButton {} noButton {} }.show()
我如何设置按钮的标题?
noButton {title = "title"}
不起作用。
你可以像这样使用positiveButton
和negativeButton
:
alert("Dialog title") { positiveButton("Yes") { dismiss() } negativeButton("No") { dismiss() } }.show()
- GridView只在单击项目时删除第一个项目。 基于Java>Kotlin
- Anko插件无法在Androidstudio版本> 2.1中运行
- 禁止“Android中不允许使用的标识符”
- Kotlin对象加载延迟
- 带有ArrayAdapter的Anko DSL
- 错误:将字节码转换为dex时出错:原因:com.android.dex.DexException:多个dex文件定义了Lorg / jetbrains / anko / collections / CollectionsKt;
- 使用Anko获取类型不匹配错误需要AnkoContext <ViewGroup>找到AnkoContext <Context>
- FirebaseDatabase根引用在事务中为空
- 可自定义parcelable对象