summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2010-04-13 12:32:28 +0200
committerhut <hut@lavabit.com>2010-04-13 12:38:40 +0200
commit01e4ea98c12a28362968a8b23483d260755838e5 (patch)
treee13c87f6f2d59ad5528f8d21443e09687f40917a
parent76aee8ea8d40a52639a52bd3d6ade13d85159ca0 (diff)
downloadranger-01e4ea98c12a28362968a8b23483d260755838e5.tar.gz
gui.bar: Fixed Zero Division Error
-rw-r--r--ranger/gui/bar.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/ranger/gui/bar.py b/ranger/gui/bar.py
index 8b8eb33c..f5e34eb1 100644
--- a/ranger/gui/bar.py
+++ b/ranger/gui/bar.py
@@ -68,7 +68,8 @@ class Bar(object):
 		rightsize = self.right.sumsize()
 		nonfixed_items = self.left.nonfixed_items()
 
-		itemsize = int(float(wid - rightsize - fixedsize) / nonfixed_items) + 1
+		itemsize = int(float(wid - rightsize - fixedsize) / \
+				(nonfixed_items + 1)) + 1
 
 		for item in self.left:
 			if not item.fixed: