From 06c27a48bc3f52e15c15445d822e8a6f523ab98f Mon Sep 17 00:00:00 2001 From: tassaron Date: Thu, 13 Jul 2017 17:03:25 -0400 Subject: more error messages for blank components --- src/components/image.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/components/image.py') diff --git a/src/components/image.py b/src/components/image.py index 6465bc9..6a70424 100644 --- a/src/components/image.py +++ b/src/components/image.py @@ -48,14 +48,15 @@ class Component(Component): def properties(self): props = ['static'] - if self.imagePath and not os.path.exists(self.imagePath): + if not os.path.exists(self.imagePath): props.append('error') return props def error(self): + if not self.imagePath: + return "There is no image selected." if not os.path.exists(self.imagePath): - return "The image selected on " \ - "layer %s does not exist!" % str(self.compPos) + return "The image selected does not exist!" def frameRender(self, layerNo, frameNo): width = int(self.settings.value('outputWidth')) -- cgit v1.2.3