Keep two digits for the opacity value in layer state
This commit is contained in:
@@ -91,7 +91,7 @@ class BaseLayer extends BaseObject {
|
||||
layer: this,
|
||||
managed: true
|
||||
});
|
||||
state.opacity = clamp(this.getOpacity(), 0, 1);
|
||||
state.opacity = clamp(Math.round(this.getOpacity() * 100) / 100, 0, 1);
|
||||
state.sourceState = this.getSourceState();
|
||||
state.visible = this.getVisible();
|
||||
state.extent = this.getExtent();
|
||||
|
||||
Reference in New Issue
Block a user