mirror of
https://github.com/jneug/zeichenmaschine.git
synced 2026-04-14 06:33:34 +02:00
Bug: Threadsafety
This commit is contained in:
@@ -48,7 +48,7 @@ public class DrawableLayer extends Layer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
synchronized( drawables ) {
|
synchronized( drawables ) {
|
||||||
List<Drawable> it = Collections.unmodifiableList(drawables);
|
List<Drawable> it = List.copyOf(drawables);
|
||||||
for( Drawable d : it ) {
|
for( Drawable d : it ) {
|
||||||
if( d.isVisible() ) {
|
if( d.isVisible() ) {
|
||||||
d.draw(drawing);
|
d.draw(drawing);
|
||||||
|
|||||||
Reference in New Issue
Block a user