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
We use the layercontrol element in parallel to the map element in a framework.
We make sure the ids for the same layer sources stay the same so that when we pass a new eox-map config the tiles do not need to be reloaded.
The problem is if any of the properties of the layer change, such as visible, opacity, (and i imagine others) through interaction in the layer control, and then a new map config is loaded, it will update the layer control but not the state of the layer in OL.
So e.g. it will show layers as full opacity (although they are not as previously they were configured to half opacity with layer control), or as visible (although they are not as previously it was toggled off) and similar things.
Sometimes properties like "visible" will actually be set in the config, but sometimes not (which should assume the default value is being considered).
Not sure how we want to address this taking into account the current map refactoring.
The text was updated successfully, but these errors were encountered:
have a tile layer with no special opacity set in the config
reduce the opacity in the EOx LayerControl to 50%
load a new layer config with the same layer ID, but let's say a different source
=> Expected behaviour: layer has 50% opacity
=> actual behaviour: layer goes back to default (100%) opacity
Not quite, i think the main issue is the disparity of layer control and actual layer state.
So steps to reproduce should be (have not tested this in a "vanilla" environment):
load eox-map config with a layer
change opacity of layer to 50% in layer controls
re-apply same eox-map config
expected behavior: layer control and map have the same state (either both show opacity 50% or both are reset to opacity 100%)
actual behavior: layer control shows slider set to 100% opacity, map shows layer with 50% opacity
@srijitcoder do you reckon this to be a good time for me to look into this? Depending on the state of the refactoring and the urgency of this issue I could look into this right now or after the refactoring
Currently as a remedy i am setting the layers configuration back to an empty array and then to the new configuration. It is not the most efficient, as it reloads all base layers and overlays every time, but i think for now is acceptable, so it is not terribly urgent.
We use the layercontrol element in parallel to the map element in a framework.
We make sure the ids for the same layer sources stay the same so that when we pass a new eox-map config the tiles do not need to be reloaded.
The problem is if any of the properties of the layer change, such as visible, opacity, (and i imagine others) through interaction in the layer control, and then a new map config is loaded, it will update the layer control but not the state of the layer in OL.
So e.g. it will show layers as full opacity (although they are not as previously they were configured to half opacity with layer control), or as visible (although they are not as previously it was toggled off) and similar things.
Sometimes properties like "visible" will actually be set in the config, but sometimes not (which should assume the default value is being considered).
Not sure how we want to address this taking into account the current map refactoring.
The text was updated successfully, but these errors were encountered: