Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/helpers.py
diff options
context:
space:
mode:
authorGary Martin <gary@garycmartin.com>2010-10-06 12:37:25 (GMT)
committer Gary Martin <gary@garycmartin.com>2010-10-06 12:37:25 (GMT)
commit5701331008c4a0173347df8d15a591f9bee56bd8 (patch)
tree1c79ce11c763af3f297cc17e0c90400f55a35667 /helpers.py
parentd946ab2b442df0118dc7e3d2d51ab30f3fb583cd (diff)
Fix crash on F14 due to Python/gtk+/pygame float/int sensitivity SL#2363.
Diffstat (limited to 'helpers.py')
-rw-r--r--helpers.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/helpers.py b/helpers.py
index 889534b..47dfbe4 100644
--- a/helpers.py
+++ b/helpers.py
@@ -137,4 +137,9 @@ def decomposePoly(vertices):
nv -= 1
# reset error detection
count = 2 * nv
- return result \ No newline at end of file
+ return result
+
+def cast_tuple_to_int(tuple):
+ """Cast tuple values to ints to avoid gtk+ and pygame's dislike of floats.
+ """
+ return [int(i) for i in tuple]