-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
我在顶层父类中 CancelAdapter,然后每个子类都根据具体情况来 CustemAdapter , 结果CustemAdapter 不起作用,因为父类实现了CancelAdapter #233
Comments
框架是默认只要引入了项目,所有页面都需要屏幕适配的,只要实现了 CancelAdapt 永远不可能走到 CustomAdapt 的逻辑; 解决方案:
if (target instanceof CancelAdapt && !target instanceof CustomAdapt) { CustomAdapt 因为要实现一些方法,你也可以自己再新建一个没有任何方法的新接口,上面的 !target instanceof CustomAdapt 改成 !target instanceof 这个新接口,你只需要让 需要适配 的子类实现这个新的接口就可以了。 或者,只对实现了新接口的类进行适配,否则全部都 AutoSize.cancelAdapt(activity); return; |
|
谢谢大佬的详细解答 |
Environment
Bug Description:
Log:
Screenshot
Related Code:
Others:
The text was updated successfully, but these errors were encountered: