From 004df12e88d1531740238ab9831577123e539196 Mon Sep 17 00:00:00 2001 From: Lex Neva Date: Sun, 30 Dec 2018 19:59:07 -0500 Subject: don't crash on a design with no stitches --- lib/gui/simulator.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/gui') diff --git a/lib/gui/simulator.py b/lib/gui/simulator.py index 0eed18c9..e0d78983 100644 --- a/lib/gui/simulator.py +++ b/lib/gui/simulator.py @@ -385,8 +385,8 @@ class DrawingPanel(wx.Panel): self.go() def choose_zoom_and_pan(self, event=None): - # ignore if called before we load the stitch plan - if not self.width and not self.height: + # ignore if EVT_SIZE fired before we load the stitch plan + if not self.width and not self.height and event is not None: return panel_width, panel_height = self.GetClientSize() -- cgit v1.2.3