commit a02b09f3b10416c34420683502e921c27274fac4
parent 2f74adca0eb58e680e9a1930c8b11e01dd40e6c4
Author: wmorgan <wmorgan@5c8cc53c-5e98-4d25-b20a-d8db53a31250>
Date: Fri, 5 Jan 2007 22:45:58 +0000
empty status when no lines
git-svn-id: svn://rubyforge.org/var/svn/sup/trunk@194 5c8cc53c-5e98-4d25-b20a-d8db53a31250
Diffstat:
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/lib/sup/modes/thread-index-mode.rb b/lib/sup/modes/thread-index-mode.rb
@@ -308,7 +308,11 @@ class ThreadIndexMode < LineCursorMode
end
def status
- "line #{curpos + 1} of #{lines} #{dirty? ? '*modified*' : ''}"
+ if (l = lines) == 0
+ ""
+ else
+ "line #{curpos + 1} of #{l} #{dirty? ? '*modified*' : ''}"
+ end
end
protected