Commit 2a02038b authored by Daniel Elstner's avatar Daniel Elstner
Browse files

:prev_match_file): There is no need to keep track of the parent iterator;

* src/filetree.cc (FileTree::prev_match_file): There is no need to
keep track of the parent iterator; just use Gtk::TreePath::size()
and TreePath::up().  Also use TreePath::push_back() instead of the
deprecated TreePath::append_index().
parent ff3a7767
2004-06-01 Daniel Elstner <daniel.elstner@gmx.net>
* src/filetree.cc (FileTree::prev_match_file): There is no need to
keep track of the parent iterator; just use Gtk::TreePath::size()
and TreePath::up(). Also use TreePath::push_back() instead of the
deprecated TreePath::append_index().
2004-06-01 Daniel Elstner <daniel.elstner@gmx.net>
* src/filetree.{cc,h} (FileTree::find_matches_at_path_iter):
......
......@@ -698,7 +698,6 @@ bool FileTree::prev_match_file(Gtk::TreeModel::iterator& iter,
g_return_val_if_fail(iter, false);
const FileTreeColumns& columns = FileTreeColumns::instance();
Gtk::TreeModel::iterator parent = iter->parent();
Gtk::TreePath path (iter);
for (;;)
......@@ -711,18 +710,16 @@ bool FileTree::prev_match_file(Gtk::TreeModel::iterator& iter,
{
if (const Gtk::TreeModel::Children& children = iter->children()) // directory?
{
parent = iter;
path.append_index(children.size());
path.push_back(children.size());
continue;
}
return true;
}
}
else if (parent)
else if (path.size() > 1)
{
path = parent;
parent = parent->parent();
path.up();
if (collapse_stack && row_expanded(path))
collapse_stack->push(path);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment