We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
mapbox-gl-js version: 0.51.0
browser: Chrome
My application subscribes to the map's render event for many reasons, eg: showing a spinner while the map renders tiles/layers.
render
I notice we get flickers of a spinner when calling setLayoutProperty on a layer and passing the same value that's already in the layer.
setLayoutProperty
visible
Click the "Test" button in this jsbin: https://jsbin.com/faqupawuho/1/edit?console,output
Calling map.setLayoutProperty('some-layer', 'visibility', 'visible') when the layer is already visible should be a no-op.
map.setLayoutProperty('some-layer', 'visibility', 'visible')
Two render events fire (see console logs in the JSBin example)
The text was updated successfully, but these errors were encountered:
same issue for me. this.map.setPaintProperty(this._rainfallId, 'raster-opacity', visible ? 0.6 : 0); it's working
this.map.setPaintProperty(this._rainfallId, 'raster-opacity', visible ? 0.6 : 0);
Sorry, something went wrong.
This was likely fixed by #7459. I'll reopen if it's not the case.
No branches or pull requests
mapbox-gl-js version:
0.51.0
browser:
Chrome
Background
My application subscribes to the map's
render
event for many reasons, eg: showing a spinner while the map renders tiles/layers.I notice we get flickers of a spinner when calling
setLayoutProperty
on a layer and passing the same value that's already in the layer.Steps to Trigger Behavior
setLayoutProperty
on a known, visible layervisible
visible
againLink to Demonstration
Click the "Test" button in this jsbin:
https://jsbin.com/faqupawuho/1/edit?console,output
Expected Behavior
Calling
map.setLayoutProperty('some-layer', 'visibility', 'visible')
when the layer is already visible should be a no-op.Actual Behavior
Two
render
events fire (see console logs in the JSBin example)The text was updated successfully, but these errors were encountered: