]> Pileus Git - ~andy/gtk/commitdiff
compare path with cursor path and not with the selected iter in the
authorKristian Rietveld <kris@gtk.org>
Mon, 11 Mar 2002 00:28:47 +0000 (00:28 +0000)
committerKristian Rietveld <kristian@src.gnome.org>
Mon, 11 Mar 2002 00:28:47 +0000 (00:28 +0000)
Mon Mar 11 01:25:14 2002  Kristian Rietveld  <kris@gtk.org>

        * gtk/gtktreeview.c (gtk_tree_view_button_press): compare path with
        cursor path and not with the selected iter in the 'decide to edit'
        check

ChangeLog
ChangeLog.pre-2-0
ChangeLog.pre-2-10
ChangeLog.pre-2-2
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gtk/gtktreeview.c

index 30c63369a77362859c8fc6bbb423a5e850ae6969..dcd76c59435270dfd8657efbab32e78f3c11643d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+Mon Mar 11 01:25:14 2002  Kristian Rietveld  <kris@gtk.org>
+
+       * gtk/gtktreeview.c (gtk_tree_view_button_press): compare path with
+       cursor path and not with the selected iter in the 'decide to edit'
+       check
+
 Fri Mar  8 14:45:00 2002  Owen Taylor  <otaylor@redhat.com>
 
        * ======== Released GTK+-2.0 ========
index 30c63369a77362859c8fc6bbb423a5e850ae6969..dcd76c59435270dfd8657efbab32e78f3c11643d 100644 (file)
@@ -1,3 +1,9 @@
+Mon Mar 11 01:25:14 2002  Kristian Rietveld  <kris@gtk.org>
+
+       * gtk/gtktreeview.c (gtk_tree_view_button_press): compare path with
+       cursor path and not with the selected iter in the 'decide to edit'
+       check
+
 Fri Mar  8 14:45:00 2002  Owen Taylor  <otaylor@redhat.com>
 
        * ======== Released GTK+-2.0 ========
index 30c63369a77362859c8fc6bbb423a5e850ae6969..dcd76c59435270dfd8657efbab32e78f3c11643d 100644 (file)
@@ -1,3 +1,9 @@
+Mon Mar 11 01:25:14 2002  Kristian Rietveld  <kris@gtk.org>
+
+       * gtk/gtktreeview.c (gtk_tree_view_button_press): compare path with
+       cursor path and not with the selected iter in the 'decide to edit'
+       check
+
 Fri Mar  8 14:45:00 2002  Owen Taylor  <otaylor@redhat.com>
 
        * ======== Released GTK+-2.0 ========
index 30c63369a77362859c8fc6bbb423a5e850ae6969..dcd76c59435270dfd8657efbab32e78f3c11643d 100644 (file)
@@ -1,3 +1,9 @@
+Mon Mar 11 01:25:14 2002  Kristian Rietveld  <kris@gtk.org>
+
+       * gtk/gtktreeview.c (gtk_tree_view_button_press): compare path with
+       cursor path and not with the selected iter in the 'decide to edit'
+       check
+
 Fri Mar  8 14:45:00 2002  Owen Taylor  <otaylor@redhat.com>
 
        * ======== Released GTK+-2.0 ========
index 30c63369a77362859c8fc6bbb423a5e850ae6969..dcd76c59435270dfd8657efbab32e78f3c11643d 100644 (file)
@@ -1,3 +1,9 @@
+Mon Mar 11 01:25:14 2002  Kristian Rietveld  <kris@gtk.org>
+
+       * gtk/gtktreeview.c (gtk_tree_view_button_press): compare path with
+       cursor path and not with the selected iter in the 'decide to edit'
+       check
+
 Fri Mar  8 14:45:00 2002  Owen Taylor  <otaylor@redhat.com>
 
        * ======== Released GTK+-2.0 ========
index 30c63369a77362859c8fc6bbb423a5e850ae6969..dcd76c59435270dfd8657efbab32e78f3c11643d 100644 (file)
@@ -1,3 +1,9 @@
+Mon Mar 11 01:25:14 2002  Kristian Rietveld  <kris@gtk.org>
+
+       * gtk/gtktreeview.c (gtk_tree_view_button_press): compare path with
+       cursor path and not with the selected iter in the 'decide to edit'
+       check
+
 Fri Mar  8 14:45:00 2002  Owen Taylor  <otaylor@redhat.com>
 
        * ======== Released GTK+-2.0 ========
index 30c63369a77362859c8fc6bbb423a5e850ae6969..dcd76c59435270dfd8657efbab32e78f3c11643d 100644 (file)
@@ -1,3 +1,9 @@
+Mon Mar 11 01:25:14 2002  Kristian Rietveld  <kris@gtk.org>
+
+       * gtk/gtktreeview.c (gtk_tree_view_button_press): compare path with
+       cursor path and not with the selected iter in the 'decide to edit'
+       check
+
 Fri Mar  8 14:45:00 2002  Owen Taylor  <otaylor@redhat.com>
 
        * ======== Released GTK+-2.0 ========
index 93a2148a26e8715a6aaa997522f1b0518a8fbf97..94f02634cb3568a73c753aefc72ee4dc1fbeba33 100644 (file)
@@ -1796,10 +1796,13 @@ gtk_tree_view_button_press (GtkWidget      *widget,
                                                (GdkEvent *)event,
                                                path_string,
                                                &background_area,
-                                               &cell_area, flags))
+                                               &cell_area, flags) &&
+             tree_view->priv->cursor)
            {
-             if (cell_editable != NULL &&
-                 gtk_tree_selection_iter_is_selected (gtk_tree_view_get_selection (tree_view), &iter))
+             GtkTreePath *cursor = gtk_tree_row_reference_get_path (tree_view->priv->cursor);
+
+             if (cell_editable != NULL && cursor &&
+                 !gtk_tree_path_compare (cursor, path))
                {
                  gtk_tree_view_real_start_editing (tree_view,
                                                    column,
@@ -1809,8 +1812,11 @@ gtk_tree_view_button_press (GtkWidget      *widget,
                                                    (GdkEvent *)event,
                                                    flags);
                  gtk_tree_path_free (path);
+                 gtk_tree_path_free (cursor);
                  return TRUE;
                }
+             if (cursor)
+               gtk_tree_path_free (cursor);
              column_handled_click = TRUE;
            }
          g_free (path_string);