You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
OnMapReadyCallback invoked when view is unmeasured #6999
Since the 4.2.0 release we are using DID_FINISH_LOADING_STYLE as event to invoke the OnMapReadyCallback. An issue noticed is that there are situations that the DID_FINISH_LOADING_STYLE event is emitted before the MapView is even measured. This currently results in using width 0 in some calculations (eg. #6769). I think we should take in account if the view is actually measured before providing the user the MapboxMap.
A way to listen if a View is measured is using a OnGlobalLayoutListener.
Picking this up as part of #7736, for that refactor I'm required to move initialization of the map object and postpone other initializations. I'm hoping that as a side effect this will result in the view being already measured when we initialize, else we need to look into including OnGlobalLayoutListener as part of the initialization.
Activity
tobrun commentedon Jan 19, 2017
Picking this up as part of #7736, for that refactor I'm required to move initialization of the map object and postpone other initializations. I'm hoping that as a side effect this will result in the view being already measured when we initialize, else we need to look into including OnGlobalLayoutListener as part of the initialization.