Zugriffe auf die Datenstrukturen des Backends werden jetzt über locks

synchronisiert.
This commit is contained in:
2014-05-01 02:09:17 +02:00
parent 3b6f407e1c
commit 98f50d3490
2 changed files with 48 additions and 23 deletions

View File

@@ -52,7 +52,9 @@ namespace WorldOfPeacecraft
{
BufferedGraphics buffer = BufferedGraphicsManager.Current.Allocate (Board.CreateGraphics (), Board.DisplayRectangle);
Graphics g = buffer.Graphics;
PaintMap(g);
lock (Backend) {
PaintMap (g);
}
buffer.Render();
}