dia r4277 - in trunk: . plug-ins/python
- From: hans svn gnome org
- To: svn-commits-list gnome org
- Subject: dia r4277 - in trunk: . plug-ins/python
- Date: Sat, 14 Feb 2009 23:30:57 +0000 (UTC)
Author: hans
Date: Sat Feb 14 23:30:57 2009
New Revision: 4277
URL: http://svn.gnome.org/viewvc/dia?rev=4277&view=rev
Log:
2009-02-14 Hans Breuer <hans breuer org>
* plug-ins/python/scascale.py : check input feasibility, bug #440884
Modified:
trunk/ChangeLog
trunk/plug-ins/python/scascale.py
Modified: trunk/plug-ins/python/scascale.py
==============================================================================
--- trunk/plug-ins/python/scascale.py (original)
+++ trunk/plug-ins/python/scascale.py Sat Feb 14 23:30:57 2009
@@ -71,9 +71,13 @@
def on_scale(self, *args) :
s = self.entry.get_text()
- SimpleScale (self.data, float(s))
- self.data.update_extents ()
- self.diagram.flush()
+ scale = float(s)
+ if scale > 0.001 and scale < 1000 :
+ SimpleScale (self.data, float(s))
+ self.data.update_extents ()
+ self.diagram.flush()
+ else :
+ dia.message(1, "Value out of range!")
self.win.destroy ()
def on_delete (self, *args) :
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]