diff options
author | Darin Adler <darin@src.gnome.org> | 2002-01-08 23:36:59 +0000 |
---|---|---|
committer | Darin Adler <darin@src.gnome.org> | 2002-01-08 23:36:59 +0000 |
commit | 8c8ba31c5d946742ae62e4cd1a17ab1a14ed8873 (patch) | |
tree | e883bee317b55ce02c334af58dfa665d1c9247aa | |
parent | 17bb5b71e75355fa3dc1d0f41cd11e22629c7fe1 (diff) | |
download | nautilus-8c8ba31c5d946742ae62e4cd1a17ab1a14ed8873.tar.gz |
Mention bad looking text.
* TODO: Mention bad looking text.
* libnautilus-private/nautilus-icon-container.c: (destroy),
(finalize), (nautilus_icon_container_init), (item_event_callback),
(nautilus_icon_container_clear):
Various fixes to make destroy on a NautilusIconContainer work.
* components/tree/nautilus-tree-view-dnd.c:
(nautilus_tree_view_drag_motion), (nautilus_tree_view_drag_drop),
(nautilus_tree_view_button_press),
(nautilus_tree_view_button_release),
(nautilus_tree_view_motion_notify):
* libnautilus-private/nautilus-undo-signal-handlers.c:
(editable_key_press_event):
* src/nautilus-bookmarks-window.c: (handle_close_accelerator):
Remove unneeded stop_emit-type calls, now that the signal machinery
understands that TRUE means to stop emitting in some cases.
-rw-r--r-- | ChangeLog | 20 | ||||
-rw-r--r-- | TODO | 3 | ||||
-rw-r--r-- | components/tree/nautilus-tree-view-dnd.c | 15 | ||||
-rw-r--r-- | libnautilus-private/nautilus-icon-container.c | 84 | ||||
-rw-r--r-- | libnautilus-private/nautilus-undo-signal-handlers.c | 2 | ||||
-rw-r--r-- | src/nautilus-bookmarks-window.c | 1 |
6 files changed, 70 insertions, 55 deletions
@@ -1,5 +1,25 @@ 2002-01-08 Darin Adler <darin@bentspoon.com> + * TODO: Mention bad looking text. + + * libnautilus-private/nautilus-icon-container.c: (destroy), + (finalize), (nautilus_icon_container_init), (item_event_callback), + (nautilus_icon_container_clear): + Various fixes to make destroy on a NautilusIconContainer work. + + * components/tree/nautilus-tree-view-dnd.c: + (nautilus_tree_view_drag_motion), (nautilus_tree_view_drag_drop), + (nautilus_tree_view_button_press), + (nautilus_tree_view_button_release), + (nautilus_tree_view_motion_notify): + * libnautilus-private/nautilus-undo-signal-handlers.c: + (editable_key_press_event): + * src/nautilus-bookmarks-window.c: (handle_close_accelerator): + Remove unneeded stop_emit-type calls, now that the signal machinery + understands that TRUE means to stop emitting in some cases. + +2002-01-08 Darin Adler <darin@bentspoon.com> + * .cvsignore: * Makefile.am: * nautilus-help.desktop.in: Remove. @@ -9,6 +9,9 @@ darin@bentspoon.com know what you are working on. - Port tree sidebar panel to GtkTreeView and then go to eel and remove EelCTree. +- Figure out why all the pangoft2-rendered text looks yucky. + Bad font choice or something? + - Visit all the GNOME2_CONVERSION_COMPLETE and fix each issue (details forthcoming) diff --git a/components/tree/nautilus-tree-view-dnd.c b/components/tree/nautilus-tree-view-dnd.c index b9c2d924f..a17b050bc 100644 --- a/components/tree/nautilus-tree-view-dnd.c +++ b/components/tree/nautilus-tree-view-dnd.c @@ -376,11 +376,6 @@ nautilus_tree_view_drag_motion (GtkWidget *widget, GdkDragContext *context, non_default_action); gdk_drag_status (context, resulting_action, time); - - - /* make sure no one will ever get this event except us */ - gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), - "drag_motion"); return TRUE; } @@ -429,8 +424,6 @@ nautilus_tree_view_drag_drop (GtkWidget *widget, dnd->drag_info->drop_occured = TRUE; get_data_on_first_target_we_support (widget, context, time); - gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), - "drag_drop"); return TRUE; } @@ -551,7 +544,7 @@ nautilus_tree_view_button_press (GtkWidget *widget, GdkEventButton *event) event->y, &press_row, &press_column); if (on_row == 0) { - gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), "button-press-event"); + gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), "button_press_event"); return FALSE; } @@ -591,8 +584,6 @@ nautilus_tree_view_button_press (GtkWidget *widget, GdkEventButton *event) } } - gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), "button-press-event"); - return TRUE; } @@ -672,8 +663,6 @@ nautilus_tree_view_button_release (GtkWidget *widget, GdkEventButton *event) } } - gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), "button-release-event"); - return TRUE; } @@ -721,8 +710,6 @@ nautilus_tree_view_motion_notify (GtkWidget *widget, GdkEventButton *event) } } - gtk_signal_emit_stop_by_name (GTK_OBJECT (widget), "motion-notify-event"); - return TRUE; } diff --git a/libnautilus-private/nautilus-icon-container.c b/libnautilus-private/nautilus-icon-container.c index 758e07544..c7d5cf838 100644 --- a/libnautilus-private/nautilus-icon-container.c +++ b/libnautilus-private/nautilus-icon-container.c @@ -119,33 +119,32 @@ enum { */ }; -static void activate_selected_items (NautilusIconContainer *container); -static void nautilus_icon_container_class_init (NautilusIconContainerClass *class); -static void nautilus_icon_container_init (NautilusIconContainer *container); -static void nautilus_icon_container_theme_changed (gpointer user_data); - -static void compute_stretch (StretchState *start, - StretchState *current); -static NautilusIcon *get_first_selected_icon (NautilusIconContainer *container); -static NautilusIcon *get_nth_selected_icon (NautilusIconContainer *container, - int index); -static gboolean has_multiple_selection (NautilusIconContainer *container); -static void icon_destroy (NautilusIconContainer *container, - NautilusIcon *icon); -static void end_renaming_mode (NautilusIconContainer *container, - gboolean commit); -static NautilusIcon *get_icon_being_renamed (NautilusIconContainer *container); -static void finish_adding_new_icons (NautilusIconContainer *container); -static void update_label_color (EelBackground *background, - NautilusIconContainer *icon_container); -static void icon_get_bounding_box (NautilusIcon *icon, - int *x1_return, - int *y1_return, - int *x2_return, - int *y2_return); -static gboolean is_renaming (NautilusIconContainer *container); -static gboolean is_renaming_pending (NautilusIconContainer *container); -static void process_pending_icon_to_rename (NautilusIconContainer *container); +static void activate_selected_items (NautilusIconContainer *container); +static void nautilus_icon_container_class_init (NautilusIconContainerClass *class); +static void nautilus_icon_container_init (NautilusIconContainer *container); +static void nautilus_icon_container_theme_changed (gpointer user_data); +static void compute_stretch (StretchState *start, + StretchState *current); +static NautilusIcon *get_first_selected_icon (NautilusIconContainer *container); +static NautilusIcon *get_nth_selected_icon (NautilusIconContainer *container, + int index); +static gboolean has_multiple_selection (NautilusIconContainer *container); +static void icon_destroy (NautilusIconContainer *container, + NautilusIcon *icon); +static void end_renaming_mode (NautilusIconContainer *container, + gboolean commit); +static NautilusIcon *get_icon_being_renamed (NautilusIconContainer *container); +static void finish_adding_new_icons (NautilusIconContainer *container); +static void update_label_color (EelBackground *background, + NautilusIconContainer *icon_container); +static void icon_get_bounding_box (NautilusIcon *icon, + int *x1_return, + int *y1_return, + int *x2_return, + int *y2_return); +static gboolean is_renaming (NautilusIconContainer *container); +static gboolean is_renaming_pending (NautilusIconContainer *container); +static void process_pending_icon_to_rename (NautilusIconContainer *container); static int click_policy_auto_value; @@ -2301,19 +2300,14 @@ destroy (GtkObject *object) if (container->details->idle_id != 0) { gtk_idle_remove (container->details->idle_id); + container->details->idle_id = 0; } if (container->details->stretch_idle_id != 0) { gtk_idle_remove (container->details->stretch_idle_id); + container->details->stretch_idle_id = 0; } - /* FIXME: The code to extract colors from the theme should be in FMDirectoryView, not here. - * The NautilusIconContainer class should simply provide calls to set the colors. - */ - eel_preferences_remove_callback (NAUTILUS_PREFERENCES_THEME, - nautilus_icon_container_theme_changed, - container); - nautilus_icon_container_flush_typeselect_state (container); EEL_CALL_PARENT (GTK_OBJECT_CLASS, destroy, (object)); @@ -2327,6 +2321,14 @@ finalize (GObject *object) details = NAUTILUS_ICON_CONTAINER (object)->details; + /* FIXME: The code to extract colors from the theme should be + * in FMDirectoryView, not here. The NautilusIconContainer + * class should simply provide calls to set the colors. + */ + eel_preferences_remove_callback (NAUTILUS_PREFERENCES_THEME, + nautilus_icon_container_theme_changed, + object); + for (i = 0; i < G_N_ELEMENTS (details->label_font); i++) { if (details->label_font[i] != NULL) gdk_font_unref (details->label_font[i]); @@ -3401,12 +3403,15 @@ nautilus_icon_container_init (NautilusIconContainer *container) g_signal_connect (container, "focus-out-event", G_CALLBACK (handle_focus_out_event), NULL); - /* FIXME: The code to extract colors from the theme should be in FMDirectoryView, not here. - * The NautilusIconContainer class should simply provide calls to set the colors. + /* FIXME: The code to extract colors from the theme should be + * in FMDirectoryView, not here. The NautilusIconContainer + * class should simply provide calls to set the colors. */ /* read in theme-dependent data */ nautilus_icon_container_theme_changed (container); - eel_preferences_add_callback (NAUTILUS_PREFERENCES_THEME, nautilus_icon_container_theme_changed, container); + eel_preferences_add_callback (NAUTILUS_PREFERENCES_THEME, + nautilus_icon_container_theme_changed, + container); } typedef struct { @@ -3564,7 +3569,6 @@ item_event_callback (GnomeCanvasItem *item, /* Stop the event from being passed along further. Returning * TRUE ain't enough. */ - gtk_signal_emit_stop_by_name (GTK_OBJECT (item), "event"); return TRUE; } return FALSE; @@ -3600,6 +3604,10 @@ nautilus_icon_container_clear (NautilusIconContainer *container) details = container->details; + if (details->icons == NULL) { + return; + } + end_renaming_mode (container, TRUE); clear_keyboard_focus (container); diff --git a/libnautilus-private/nautilus-undo-signal-handlers.c b/libnautilus-private/nautilus-undo-signal-handlers.c index 82040b7cd..2ad988334 100644 --- a/libnautilus-private/nautilus-undo-signal-handlers.c +++ b/libnautilus-private/nautilus-undo-signal-handlers.c @@ -300,8 +300,6 @@ editable_key_press_event (GtkEditable *editable, GdkEventKey *event, gpointer us case 'z': if ((event->state & GDK_CONTROL_MASK) != 0) { nautilus_undo (GTK_OBJECT (editable)); - gtk_signal_emit_stop_by_name (GTK_OBJECT (editable), - "key_press_event"); return TRUE; } break; diff --git a/src/nautilus-bookmarks-window.c b/src/nautilus-bookmarks-window.c index 772367e73..3753815ea 100644 --- a/src/nautilus-bookmarks-window.c +++ b/src/nautilus-bookmarks-window.c @@ -636,7 +636,6 @@ handle_close_accelerator (GtkWindow *window, if (eel_gtk_window_event_is_close_accelerator (window, event)) { gtk_widget_hide (GTK_WIDGET (window)); - gtk_signal_emit_stop_by_name (GTK_OBJECT (window), "key_press_event"); return TRUE; } |