Mercurial > geeqie
diff src/view_dir_tree.c @ 1631:2349fa90226d
better implementation of tree_view_row_get_visibility,
gtk_tree_view_set_cursor is not sufficient in some cases, call also
tree_view_row_make_visible
author | nadvornik |
---|---|
date | Sat, 06 Jun 2009 16:14:07 +0000 |
parents | a5c1930c4437 |
children | 956aab097ea7 |
line wrap: on
line diff
--- a/src/view_dir_tree.c Sat Jun 06 15:33:56 2009 +0000 +++ b/src/view_dir_tree.c Sat Jun 06 16:14:07 2009 +0000 @@ -720,6 +720,10 @@ { /* setting the cursor scrolls the view; do not do that unless it is necessary */ gtk_tree_view_set_cursor(GTK_TREE_VIEW(vd->view), tpath, NULL, FALSE); + + /* gtk_tree_view_set_cursor scrolls the window itself, but it sometimes + does not work (switch from dir_list to dir_tree) */ + tree_view_row_make_visible(GTK_TREE_VIEW(vd->view), &iter, TRUE); } gtk_tree_path_free(tpath); gtk_tree_path_free(old_tpath);