Proper '/' on the end of directories in the find-file window.

git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@381 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
rakshasa
2005-04-03 16:36:19 +00:00
parent fe11d1936d
commit 874e46fc64
15 changed files with 216 additions and 24 deletions
+10 -2
View File
@@ -45,14 +45,18 @@ WindowStringList::redraw() {
size_t xpos = 1;
size_t width = 0;
for (iterator itr = m_first; itr != m_last; ++itr) {
iterator itr = m_first;
while (itr != m_last) {
if (ypos == (size_t)m_canvas->get_height()) {
ypos = 0;
xpos += width + 2;
if (xpos >= (size_t)m_canvas->get_width())
if (xpos + 20 >= (size_t)m_canvas->get_width())
break;
width = 0;
}
width = std::max(itr->size(), width);
@@ -61,7 +65,11 @@ WindowStringList::redraw() {
m_canvas->print(xpos, ypos++, "%s", itr->c_str());
else
m_canvas->print(xpos, ypos++, "%s", itr->substr(0, m_canvas->get_width() - xpos).c_str());
++itr;
}
m_drawEnd = itr;
}
}