about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--TODO1
-rw-r--r--ranger/gui/curses_shortcuts.py6
-rw-r--r--ranger/gui/widgets/browserview.py2
3 files changed, 8 insertions, 1 deletions
diff --git a/TODO b/TODO
index 2b996543..ffafc92d 100644
--- a/TODO
+++ b/TODO
@@ -26,3 +26,4 @@ Bugs
 
    ( ) #17  10/01/01  why do bookmarks disappear sometimes?
    ( ) #18  10/01/01  fix notify widget (by adding a LogView?)
+   ( ) #19  10/01/01  resizing after pressing g
diff --git a/ranger/gui/curses_shortcuts.py b/ranger/gui/curses_shortcuts.py
index b85a2de9..6d1bd7e9 100644
--- a/ranger/gui/curses_shortcuts.py
+++ b/ranger/gui/curses_shortcuts.py
@@ -18,6 +18,12 @@ class CursesShortcuts(SettingsAware):
 		except _curses.error:
 			pass
 
+	def addnstr(self, *args):
+		try:
+			self.win.addnstr(*args)
+		except _curses.error:
+			pass
+
 	def color(self, keylist = None, *keys):
 		"""Change the colors from now on."""
 		keys = combine(keylist, keys)
diff --git a/ranger/gui/widgets/browserview.py b/ranger/gui/widgets/browserview.py
index c638f15d..7238d95f 100644
--- a/ranger/gui/widgets/browserview.py
+++ b/ranger/gui/widgets/browserview.py
@@ -67,7 +67,7 @@ class BrowserView(Widget, DisplayableContainer):
 		for line, items in generator():
 			key, mark = items
 			string = " " + key + ": " + mark.path
-			self.addstr(line, 0, string.ljust(maxlen))
+			self.addnstr(line, 0, string.ljust(maxlen), self.wid)
 	
 	def resize(self, y, x, hei, wid):
 		"""Resize all the columns according to the given ratio"""