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

Failed to bind EAGLDrawable #196

Closed
bigdaddio opened this issue Jan 19, 2018 · 3 comments
Closed

Failed to bind EAGLDrawable #196

bigdaddio opened this issue Jan 19, 2018 · 3 comments

Comments

@bigdaddio
Copy link

I get this error and of course no map.
Page1 I create and draw a map via XML.
(destroy map and go to Page2)
Page 2 something else
page 3 something else
Page4 try to create another map XML and get the error.
This is how I create the map on both pages. However the first page I have the map fullscreen.
I also found this error on mapbox-gl-native project and wonder if they could be related?

<StackLayout width="100%" height="60%" backgroundColor="blue" >
            <map:MapboxView
                delay="0"
                latitude="0"
                longitude="0"
                zoomLevel="13"
                disableZoom="false"
                disableRotation="true"
                disableScroll="false"
                disableTilt="true"
                showUserLocation="true"
                hideAttribution="true"
                mapStyle="emerald"
                hideLogo="true"
                accessToken="***"
                mapReady="onMapReady">
            </map:MapboxView>
</StackLayout>
@EddyVerbruggen
Copy link
Collaborator

Can you link to that issue?

@bigdaddio
Copy link
Author

bigdaddio commented Jan 19, 2018

@EddyVerbruggen
Copy link
Collaborator

Thank you.

I have not seen this issue myself, but changing the embedded demo app from a GridLayout to your StackLayout doesn't render a map (without an error). So I started digging.

Turns out the height property of the StackLayout isn't propagated down to the MapboxView automatically (the width is) so the height is 0 and the map is invisible.

I've changed the plugin code to apply the parent width/height if you didn't explicitly set those properties on the MapboxView object, and now the map will automatically fill the available space in the parent container.

@EddyVerbruggen EddyVerbruggen added this to the 3.3.0 milestone Jan 20, 2018
EddyVerbruggen added a commit that referenced this issue Jan 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants