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

ViewState screenSize not set on iOS #162

Open
mtehver opened this issue Nov 28, 2017 · 0 comments
Open

ViewState screenSize not set on iOS #162

mtehver opened this issue Nov 28, 2017 · 0 comments

Comments

@mtehver
Copy link
Contributor

mtehver commented Nov 28, 2017

ScreenSize is set asynchronously using the main queue on iOS and as a result screen <-> map conversion functions do not work properly in methods like viewDidLoad. A workaround is to store the view size as early as possible (in layoutSubviews method), even before the GL context has been created.

A similar issue exists on Android. In onCreate method the layout has not yet been determined. On Android ViewTreeObserver.OnGlobalLayoutListener should be used.

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

1 participant