Commit 56de1e56 authored by Gene Z. Ragan's avatar Gene Z. Ragan Committed by Gene Ragan
Browse files

Fixed bug 2197, moving a file to trash while in renaming mode leaves

2000-08-16  Gene Z. Ragan  <gzr@eazel.com>

	* libnautilus-extensions/nautilus-icon-container.c:
	(icon_toggle_selected), (icon_destroy),
	(nautilus_icon_container_remove):
	Fixed bug 2197, moving a file to trash while in renaming mode
	leaves renaiming item behind.
	Call end_renaming_mode in nautilus_icon_container_remove.

	* libnautilus-extensions/nautilus-icon-dnd.c:
	(nautilus_icon_container_free_drag_data):
	Changed gtk_object_unref call to gtk_object_destroy to
	fix a crash.  Hopefully this didn't
	introduce a memory leak.
parent 7bf5da1b
2000-08-16 Gene Z. Ragan <gzr@eazel.com>
* libnautilus-extensions/nautilus-icon-container.c:
(icon_toggle_selected), (icon_destroy),
(nautilus_icon_container_remove):
Fixed bug 2197, moving a file to trash while in renaming mode
leaves renaiming item behind.
Call end_renaming_mode in nautilus_icon_container_remove.
* libnautilus-extensions/nautilus-icon-dnd.c:
(nautilus_icon_container_free_drag_data):
Changed gtk_object_unref call to gtk_object_destroy to
fix a crash. Hopefully this didn't
introduce a memory leak.
2000-08-16 Darin Adler <darin@eazel.com>
* README: Don't use tabs any more. Spell check.
......
......@@ -270,7 +270,7 @@ static void
icon_toggle_selected (NautilusIconContainer *container,
NautilusIcon *icon)
{
end_renaming_mode(container, TRUE);
end_renaming_mode (container, TRUE);
icon->is_selected = !icon->is_selected;
gnome_canvas_item_set (GNOME_CANVAS_ITEM (icon->item),
......@@ -3195,7 +3195,7 @@ icon_destroy (NautilusIconContainer *container,
details = container->details;
details->icons = g_list_remove (details->icons, icon);
was_selected = icon->is_selected;
if (details->keyboard_focus == icon) {
......@@ -3495,6 +3495,8 @@ nautilus_icon_container_remove (NautilusIconContainer *container,
g_return_val_if_fail (NAUTILUS_IS_ICON_CONTAINER (container), FALSE);
g_return_val_if_fail (data != NULL, FALSE);
end_renaming_mode (container, FALSE);
/* FIXME bugzilla.eazel.com 1288:
* I guess we need to use an indexed data structure to avoid this loop.
*/
......
......@@ -1006,7 +1006,7 @@ nautilus_icon_container_free_drag_data (NautilusIconContainer *container)
dnd_info->drag_info.got_drop_data_type = FALSE;
if (dnd_info->shadow != NULL) {
gtk_object_unref (GTK_OBJECT (dnd_info->shadow));
gtk_object_destroy (GTK_OBJECT (dnd_info->shadow));
dnd_info->shadow = NULL;
}
......
......@@ -270,7 +270,7 @@ static void
icon_toggle_selected (NautilusIconContainer *container,
NautilusIcon *icon)
{
end_renaming_mode(container, TRUE);
end_renaming_mode (container, TRUE);
icon->is_selected = !icon->is_selected;
gnome_canvas_item_set (GNOME_CANVAS_ITEM (icon->item),
......@@ -3195,7 +3195,7 @@ icon_destroy (NautilusIconContainer *container,
details = container->details;
details->icons = g_list_remove (details->icons, icon);
was_selected = icon->is_selected;
if (details->keyboard_focus == icon) {
......@@ -3495,6 +3495,8 @@ nautilus_icon_container_remove (NautilusIconContainer *container,
g_return_val_if_fail (NAUTILUS_IS_ICON_CONTAINER (container), FALSE);
g_return_val_if_fail (data != NULL, FALSE);
end_renaming_mode (container, FALSE);
/* FIXME bugzilla.eazel.com 1288:
* I guess we need to use an indexed data structure to avoid this loop.
*/
......
......@@ -1006,7 +1006,7 @@ nautilus_icon_container_free_drag_data (NautilusIconContainer *container)
dnd_info->drag_info.got_drop_data_type = FALSE;
if (dnd_info->shadow != NULL) {
gtk_object_unref (GTK_OBJECT (dnd_info->shadow));
gtk_object_destroy (GTK_OBJECT (dnd_info->shadow));
dnd_info->shadow = NULL;
}
......
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