mylhyl / android-circledialog Goto Github PK
View Code? Open in Web Editor NEW仿IOS圆角对话框、进度条、列表框、输入框,ad广告框,支持横竖屏切换
仿IOS圆角对话框、进度条、列表框、输入框,ad广告框,支持横竖屏切换
请问如果要实现竖屏时dialog从底部弹出,横屏时从左侧弹出
就是type=password的那种
但是BaseCircleDialog是final的 不能被继承
1首先在页面点击显示弹窗然后点击返回(此时弹窗消失)
2在点击返回(此时页面返回到上一页)
3重新进入有弹窗的那个页面点击弹出按钮(此时弹窗不显示了)
.configDialog(new ConfigDialog() {
@OverRide
public void onConfig(DialogParams params) {
params.backgroundColor = Color.BLACK;
}
})
.show();
设置di'alog背景无颜色无效
timer.cancel(); 无效
请问如何解决
15506-11 12:18:41.674 11249 11249 E AndroidRuntime: at com.mylhyl.circledialog.view.BuildViewImpl.buildItems(BuildViewImpl.java:88)
15606-11 12:18:41.674 11249 11249 E AndroidRuntime: at com.mylhyl.circledialog.Controller.applyBody(Controller.java:82)
15706-11 12:18:41.674 11249 11249 E AndroidRuntime: at com.mylhyl.circledialog.Controller.createView(Controller.java:53)
15806-11 12:18:41.674 11249 11249 E AndroidRuntime: at com.mylhyl.circledialog.AbsCircleDialog.createView(AbsCircleDialog.java:50)
15906-11 12:18:41.674 11249 11249 E AndroidRuntime: at com.mylhyl.circledialog.BaseCircleDialog.onCreateView(BaseCircleDialog.java:70)
16006-11 12:18:41.674 11249 11249 E AndroidRuntime: at android.support.v4.app.Fragment.performCreateView(Fragment.java:2439)
16106-11 12:18:41.674 11249 11249 E AndroidRuntime: at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1460)
16206-11 12:18:41.674 11249 11249 E AndroidRuntime: at android.support.v4.app.FragmentManagerImpl.moveFragmentToExpectedState(FragmentManager.java:1784)
16306-11 12:18:41.674 11249 11249 E AndroidRuntime: at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1852)
16406-11 12:18:41.674 11249 11249 E AndroidRuntime: at android.support.v4.app.FragmentManagerImpl.dispatchStateChange(FragmentManager.java:3269)
16506-11 12:18:41.674 11249 11249 E AndroidRuntime: at android.support.v4.app.FragmentManagerImpl.dispatchActivityCreated(FragmentManager.java:3229)
16606-11 12:18:41.674 11249 11249 E AndroidRuntime: at android.support.v4.app.FragmentController.dispatchActivityCreated(FragmentController.java:201)
尝试设置params.animStyle依旧有这个动画效果,无法像原生PopupWindow一样设置AnimationStyle
java.lang.RuntimeException: Parcelable encountered IOException writing serializable object (name = com.mylhyl.circledialog.params.CircleParams)
at android.os.Parcel.writeSerializable(Parcel.java:1279)
at android.os.Parcel.writeValue(Parcel.java:1233)
at android.os.Parcel.writeMapInternal(Parcel.java:591)
at android.os.Bundle.writeToParcel(Bundle.java:1627)
at android.os.Parcel.writeBundle(Parcel.java:605)
at android.support.v4.app.FragmentState.writeToParcel(Fragment.java:137)
at android.os.Parcel.writeTypedArray(Parcel.java:1102)
at android.support.v4.app.FragmentManagerState.writeToParcel(FragmentManager.java:385)
at android.os.Parcel.writeParcelable(Parcel.java:1254)
at android.os.Parcel.writeValue(Parcel.java:1173)
at android.os.Parcel.writeMapInternal(Parcel.java:591)
at android.os.Bundle.writeToParcel(Bundle.java:1627)
at android.os.Parcel.writeBundle(Parcel.java:605)
at android.app.ActivityManagerProxy.activityStopped(ActivityManagerNative.java:2252)
at android.app.ActivityThread$StopInfo.run(ActivityThread.java:3052)
at android.os.Handler.handleCallback(Handler.java:725)
at android.os.Handler.dispatchMessage(Handler.java:92)
circledialog at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:5041)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.io.NotSerializableException: com.mylhyl.circledialog.AbsCircleDialog
at java.io.ObjectOutputStream.writeNewObject(ObjectOutputStream.java:1364)
at java.io.ObjectOutputStream.writeObjectInternal(ObjectOutputStream.java:1671)
at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:1517)
at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:1481)
V3.0.8版本使用setBodyView()方法自定义对话框内容时,Positive、Negative等按钮就不能显示了,Demo中的“自定义内容视图”例子也有此问题,V2版本正常。
Error:(69, 13) Failed to resolve: com.mylhyl:circleDialog:2.0.0
输入框的告诉设置高速 输入的东西完全看不到,并且怎么获取到输入的值
建议在CircleDialog类中,dissmiss()的地方使用dismissAllowingStateLoss()
否则可能引发
IllegalStateException: Can not perform this action after onSaveInstanceState
java.lang.NullPointerException:Attempt to invoke interface method 'android.view.View com.mylhyl.circledialog.view.listener.ItemsView.getView()' on a null object reference
出现了空指针异常,请问
@OverRide
public ItemsView buildItems() {
if (mItemsView == null) {
if (mParams.itemListener != null || mParams.itemsParams.adapter != null)
mItemsView = new BodyItemsView(mContext, mParams);
else if (mParams.rvItemListener != null || mParams.itemsParams.adapterRv != null)
mItemsView = new BodyItemsRvView(mContext, mParams);
mRoot.addView(mItemsView.getView());
}
return mItemsView;
}
这个怎么会为空呢,是因为设备部兼容么
你好, setText 能垂直居中吗, 离title有点远 没有subtitle的情况下能否是 text文本在 按钮和title中间显示。
目前输入框gravity默认是左上角 setGravity(Gravity.TOP | Gravity.LEFT)。且外部无法修改,希望能够公开这个接口,谢谢!
设置setMaxHeight 没用哎,求解决
show(getSupportFragmentManager())最后显示的部分似乎都是这个写法,这就造成了circleDialog的显示必须依赖于activity或者是fragment,能不能后期将dialog做成不依赖与界面,在其他类里面也可以自由调用呢?
private void createItemDecoration() {
if (mItemsParams.dividerHeight > 0 && !(mLayoutManager instanceof LayoutManager)) {
}
}
这个取非应该是大佬手误吧?
!(mLayoutManager instanceof LayoutManager)
我按属性设置没有用 显示不出来
.setCancelable(false)
.setInputManualClose(true)
这两个设置了也没有用 是后面的冲突了嘛
new CircleDialog.Builder()
.configDialog(new ConfigDialog() {
@OverRide
public void onConfig(DialogParams params) {
params.backgroundColorPress = Color.GRAY;
}
})
.setTitle("选择特殊车辆类型[可不选择]")
.setItems(singleAdapter, new AdapterView.OnItemClickListener() {
@OverRide
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
singleAdapter.toggle(position, objects[position]);
}
})
.setGravity(Gravity.CENTER)//显示居中
.setItemsManualClose(true)
.setNegative("取消", null)
.setPositive("下一步", new View.OnClickListener() {
@OverRide
public void onClick(View v) {
}
})
.show(getSupportFragmentManager());
只设置titile 不设置text 报这个错误com.mylhyl.circledialog.BuildView.buildButton()' on a null object reference 我的需求是 只显示一个按钮 显示title 不需要text
ButtonParams 没有设置textstyle的接口
很多局限性
1,AndroidManifest 设置参数没用,依旧是那么大,建议能增加带宽高度的构造函数或解决bug
2.建议增加设置标题高度,标题字体颜色的函数;
3.建议增加内容颜色的函数
log.txt;复现此现象的方法:设置--开发者选项--不保留活动(打开开关);
请问设置数据 能传自己的数据类型吗? 如何设置我想要的数据类型的参数为显示内容
我使用listview或recyclerview作为弹框后,我数据源很多,即列表很多,那弹框的高度怎么限制,我设置setMaxHeight 没效果,不然他就充满整个屏幕了,不好看,求解决,谢谢
项目中 com.github.CymChad:BaseRecyclerViewAdapterHelper:2.9.40 导致了我冲突
InputParams 没找到设置padding属性
大家对Android-CircleDialog有什么好的建议,都可以在此留言
多个网络请求,提示对话框弹了多次,请问我应该如何处理一下,让它只弹一次就行?
PromptDialog 写在baseactivity里的。
项目中没有使用AndroidX如何使用该库呢
在Adapter里面用会报这个错Process 'command 'D:\Program Files\Android\Android Studio\jre\bin\java.exe'' finished with non-zero exit value 1
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.