[Xfce4-commits] r23252 - in thunar/trunk: . thunar
Benedikt Meurer
benny at xfce.org
Sun Oct 1 12:22:21 UTC 2006
Author: benny
Date: 2006-10-01 12:22:19 +0000 (Sun, 01 Oct 2006)
New Revision: 23252
Modified:
thunar/trunk/ChangeLog
thunar/trunk/thunar/thunar-standard-view.c
Log:
2006-10-01 Benedikt Meurer <benny at xfce.org>
* thunar/thunar-standard-view.c
(thunar_standard_view_set_selected_files): Place the cursor on the
first selected file. Bug #2368.
Modified: thunar/trunk/ChangeLog
===================================================================
--- thunar/trunk/ChangeLog 2006-10-01 11:19:30 UTC (rev 23251)
+++ thunar/trunk/ChangeLog 2006-10-01 12:22:19 UTC (rev 23252)
@@ -1,5 +1,11 @@
2006-10-01 Benedikt Meurer <benny at xfce.org>
+ * thunar/thunar-standard-view.c
+ (thunar_standard_view_set_selected_files): Place the cursor on the
+ first selected file. Bug #2368.
+
+2006-10-01 Benedikt Meurer <benny at xfce.org>
+
* configure.in.in: Depend on exo 0.3.1.11 because thunar-uca requires
exo-open to support the --working-directory switch.
Modified: thunar/trunk/thunar/thunar-standard-view.c
===================================================================
--- thunar/trunk/thunar/thunar-standard-view.c 2006-10-01 11:19:30 UTC (rev 23251)
+++ thunar/trunk/thunar/thunar-standard-view.c 2006-10-01 12:22:19 UTC (rev 23252)
@@ -1007,13 +1007,20 @@
paths = thunar_list_model_get_paths_for_files (standard_view->model, selected_files);
if (G_LIKELY (paths != NULL))
{
- /* select the given tree paths */
+ /* determine the first path */
for (first_path = paths->data, lp = paths; lp != NULL; lp = lp->next)
{
/* check if this path is located before the current first_path */
if (gtk_tree_path_compare (lp->data, first_path) < 0)
first_path = lp->data;
+ }
+ /* place the cursor on the first selected path (must be first for GtkTreeView) */
+ (*THUNAR_STANDARD_VIEW_GET_CLASS (standard_view)->set_cursor) (standard_view, first_path, FALSE);
+
+ /* select the given tree paths paths */
+ for (first_path = paths->data, lp = paths; lp != NULL; lp = lp->next)
+ {
/* select the path */
(*THUNAR_STANDARD_VIEW_GET_CLASS (standard_view)->select_path) (standard_view, lp->data);
}
More information about the Xfce4-commits
mailing list