Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 10 additions & 7 deletions src/essence/Basics/Layers_/Layers_.js
Original file line number Diff line number Diff line change
Expand Up @@ -587,13 +587,16 @@ const L_ = {
}

if (s.type === 'image') {
L_.layers.layer[s.name].clearCache()
L_.layers.layer[s.name].updateColors(
L_.layers.layer[s.name].options
.pixelValuesToColorFn
)
// Redraw the layer or the image will not refresh again unless zooming in/out
L_.layers.layer[s.name].redraw()
if (L_.layers.layer[s.name].options.pixelValuesToColorFn
&& L_.layers.layer[s.name].options.pixelValuesToColorFn !== null) {
L_.layers.layer[s.name].clearCache()
L_.layers.layer[s.name].updateColors(
L_.layers.layer[s.name].options
.pixelValuesToColorFn
)
// Redraw the layer or the image will not refresh again unless zooming in/out
L_.layers.layer[s.name].redraw()
}
}

if (s.type === 'vector') {
Expand Down