单击以显示对话框,发生此错误
java.lang.RuntimeException:未知的animation-name:cn.pedant.SweetAlert.Rotate3dAnimation错误:null
有人一步一步解决问题吗?
evi*_*hok 13
使用这个库与新功能相同 https://jitpack.io/p/Leogiroux/sweet-alert-dialog
将此库添加到app/build.gradle:
dependencies {
...
implementation 'com.github.f0ris.sweetalert:library:1.5.1'
}
Run Code Online (Sandbox Code Playgroud)
用法:
SweetAlertDialog pDialog = new SweetAlertDialog(this, SweetAlertDialog.PROGRESS_TYPE);
pDialog.getProgressHelper().setBarColor(Color.parseColor("#A5DC86"));
pDialog.setTitleText("Loading");
pDialog.setCancelable(false);
pDialog.show();
Run Code Online (Sandbox Code Playgroud)
有关进度的更多用法,请阅读THIS。
小智 5
将此库添加到app/build.gradle:
dependencies {
...
implementation 'com.github.f0ris.sweetalert:library:1.5.1'
}
这将解决您的问题。
小智 5
我得到了解决方案!
如果您使用的是implementation 'cn.pedant.sweetalert:library:1.3'库,只需在proguard-rules.pro文件中添加以下行。
-keep class cn.pedant.** { *; }
| 归档时间: |
|
| 查看次数: |
12727 次 |
| 最近记录: |