take into account that a path from a rowref can be NULL. (#72623 and

Tue Feb 26 19:47:16 2002  Kristian Rietveld  <kris@gtk.org>

        * gtk/gtktreeview.c (validate_visible_area): take into account
        that a path from a rowref can be NULL. (#72623 and #72650)

        * gtk/gtktreeviewcolumn.c (gtk_tree_view_column_cell_render_or_focus):
        let focus_rectangle be the same as cell_area for empty cells (#69900)
This commit is contained in:
Kristian Rietveld 2002-02-26 18:56:53 +00:00 committed by Kristian Rietveld
parent f255d50bbf
commit 07d3ebd017
9 changed files with 66 additions and 6 deletions

View File

@ -1,3 +1,11 @@
Tue Feb 26 19:47:16 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): take into account
that a path from a rowref can be NULL. (#72623 and #72650)
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_cell_render_or_focus):
let focus_rectangle be the same as cell_area for empty cells (#69900)
Tue Feb 26 11:51:56 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkkeyhash.c (_gtk_key_hash_remove_entry): Fix

View File

@ -1,3 +1,11 @@
Tue Feb 26 19:47:16 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): take into account
that a path from a rowref can be NULL. (#72623 and #72650)
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_cell_render_or_focus):
let focus_rectangle be the same as cell_area for empty cells (#69900)
Tue Feb 26 11:51:56 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkkeyhash.c (_gtk_key_hash_remove_entry): Fix

View File

@ -1,3 +1,11 @@
Tue Feb 26 19:47:16 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): take into account
that a path from a rowref can be NULL. (#72623 and #72650)
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_cell_render_or_focus):
let focus_rectangle be the same as cell_area for empty cells (#69900)
Tue Feb 26 11:51:56 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkkeyhash.c (_gtk_key_hash_remove_entry): Fix

View File

@ -1,3 +1,11 @@
Tue Feb 26 19:47:16 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): take into account
that a path from a rowref can be NULL. (#72623 and #72650)
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_cell_render_or_focus):
let focus_rectangle be the same as cell_area for empty cells (#69900)
Tue Feb 26 11:51:56 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkkeyhash.c (_gtk_key_hash_remove_entry): Fix

View File

@ -1,3 +1,11 @@
Tue Feb 26 19:47:16 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): take into account
that a path from a rowref can be NULL. (#72623 and #72650)
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_cell_render_or_focus):
let focus_rectangle be the same as cell_area for empty cells (#69900)
Tue Feb 26 11:51:56 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkkeyhash.c (_gtk_key_hash_remove_entry): Fix

View File

@ -1,3 +1,11 @@
Tue Feb 26 19:47:16 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): take into account
that a path from a rowref can be NULL. (#72623 and #72650)
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_cell_render_or_focus):
let focus_rectangle be the same as cell_area for empty cells (#69900)
Tue Feb 26 11:51:56 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkkeyhash.c (_gtk_key_hash_remove_entry): Fix

View File

@ -1,3 +1,11 @@
Tue Feb 26 19:47:16 2002 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeview.c (validate_visible_area): take into account
that a path from a rowref can be NULL. (#72623 and #72650)
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_cell_render_or_focus):
let focus_rectangle be the same as cell_area for empty cells (#69900)
Tue Feb 26 11:51:56 2002 Owen Taylor <otaylor@redhat.com>
* gtk/gtkkeyhash.c (_gtk_key_hash_remove_entry): Fix

View File

@ -3678,7 +3678,7 @@ validate_visible_area (GtkTreeView *tree_view)
if (tree_view->priv->scroll_to_path)
{
path = gtk_tree_row_reference_get_path (tree_view->priv->scroll_to_path);
if (!_gtk_tree_view_find_node (tree_view, path, &tree, &node))
if (path && !_gtk_tree_view_find_node (tree_view, path, &tree, &node))
{
gtk_tree_model_get_iter (tree_view->priv->model, &iter, path);
if (GTK_RBNODE_FLAG_SET (node, GTK_RBNODE_INVALID) ||
@ -3707,7 +3707,13 @@ validate_visible_area (GtkTreeView *tree_view)
/* the scroll to isn't valid; ignore it.
*/
{
gtk_tree_path_free (path);
if (tree_view->priv->scroll_to_path && !path)
{
gtk_tree_row_reference_free (tree_view->priv->scroll_to_path);
tree_view->priv->scroll_to_path = NULL;
}
if (path)
gtk_tree_path_free (path);
path = NULL;
}
}

View File

@ -2370,10 +2370,8 @@ gtk_tree_view_column_cell_render_or_focus (GtkTreeViewColumn *tree_column,
if (min_x >= max_x || min_y >= max_y)
{
*focus_rectangle = *cell_area;
focus_rectangle->x -= focus_line_width;
focus_rectangle->y -= focus_line_width;
focus_rectangle->width += 2 * focus_line_width;
focus_rectangle->height += 2 * focus_line_width;
/* don't change the focus_rectangle, just draw it nicely inside
* the cell area */
}
else
{