Skip to content
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

The onLazyInit callback is often not called after upgrading to 1.0.6 #11

Closed
HuuNguyen312 opened this issue Jun 8, 2020 · 4 comments
Closed

Comments

@HuuNguyen312
Copy link

Dear @JantHsueh,

I faced the issue "The onLazyInit callback is often not called" on all our devices. (Samsung S10 plus, Nokia 5.1, ...).
I force rollback 1.0.5 version to hotfix this issue.

Please help me fix this issue.
Thanks

@JantHsueh
Copy link
Owner

1、the lazyInitView() will only be executed when it is visible for the first time,
2、Is onSupportVisible running normally? If normal, please describe the steps to reproduce this issues

@HuuNguyen312
Copy link
Author

HuuNguyen312 commented Jun 10, 2020

1、the lazyInitView() will only be executed when it is visible for the first time,

I have been using this library for 2 years, so I understand it.

This is a log of callback

2020-06-10 14:11:43.775 22446-22446 onCreate
2020-06-10 14:11:43.777 22446-22446 onCreateView
2020-06-10 14:11:43.899 22446-22446 onViewCreated

The lazyInitView and onSupportVisible aren't called
I just start fragment by a normal way "start(fragmentA)

I used the code of 1.0.6 version, and VisibleDelegate (using 1.0.5). It is working properly.
It seems the problem is VisibleDelegate.

@JantHsueh
Copy link
Owner

In the demo and my project, the method is normal, and test phone is pixel 2. Can you test with demo, Is there the same problem

@HuuNguyen312
Copy link
Author

I have no problem with the demo project. It just happened on my project.
The backstack has many stacks.

I don't understand why you use Looper.myQueue().addIdleHandler instead of getHandler().post
I have tried to keep your version 1.0.6, only using getHandler ().post
--> This issue is resolved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants