[nautilus] icon-info: remove code for unused .icon file functionality



commit 67fdde6a9ff2dcbe3ae25fa3e259e77a4951cc46
Author: Cosimo Cecchi <cosimoc gnome org>
Date:   Sat Aug 30 12:01:34 2014 -0700

    icon-info: remove code for unused .icon file functionality
    
    GTK+ deprecated the functionality from GtkIconInfo, and will now always
    return empty data. We can then just remove all the code related to that
    feature.

 libnautilus-private/nautilus-canvas-container.c  |   84 +-------
 libnautilus-private/nautilus-canvas-container.h  |   10 -
 libnautilus-private/nautilus-canvas-item.c       |  129 -----------
 libnautilus-private/nautilus-canvas-item.h       |    7 -
 libnautilus-private/nautilus-canvas-private.h    |    3 -
 libnautilus-private/nautilus-directory-async.c   |  253 ----------------------
 libnautilus-private/nautilus-directory-private.h |    4 -
 libnautilus-private/nautilus-directory.c         |    2 -
 libnautilus-private/nautilus-file-private.h      |   21 --
 libnautilus-private/nautilus-file.c              |  218 -------------------
 libnautilus-private/nautilus-file.h              |    4 -
 libnautilus-private/nautilus-icon-info.c         |   43 ----
 libnautilus-private/nautilus-icon-info.h         |    6 -
 src/nautilus-canvas-view-container.c             |   49 -----
 14 files changed, 1 insertions(+), 832 deletions(-)
---
diff --git a/libnautilus-private/nautilus-canvas-container.c b/libnautilus-private/nautilus-canvas-container.c
index f223a6e..3294b43 100644
--- a/libnautilus-private/nautilus-canvas-container.c
+++ b/libnautilus-private/nautilus-canvas-container.c
@@ -105,14 +105,6 @@
 #define SNAP_SIZE_X            78
 #define SNAP_SIZE_Y            20
 
-#define MINIMUM_EMBEDDED_TEXT_RECT_WIDTH       20
-#define MINIMUM_EMBEDDED_TEXT_RECT_HEIGHT      20
-
-/* If icon size is bigger than this, request large embedded text.
- * Its selected so that the non-large text should fit in "normal" icon sizes
- */
-#define ICON_SIZE_FOR_LARGE_EMBEDDED_TEXT 55
-
 #define SNAP_HORIZONTAL(func,x) ((func ((double)((x) - DESKTOP_PAD_HORIZONTAL) / SNAP_SIZE_X) * SNAP_SIZE_X) 
+ DESKTOP_PAD_HORIZONTAL)
 #define SNAP_VERTICAL(func, y) ((func ((double)((y) - DESKTOP_PAD_VERTICAL) / SNAP_SIZE_Y) * SNAP_SIZE_Y) + 
DESKTOP_PAD_VERTICAL)
 
@@ -167,13 +159,6 @@ static inline void   icon_get_bounding_box                          (NautilusCan
 static gboolean      is_renaming                                    (NautilusCanvasContainer *container);
 static gboolean      is_renaming_pending                            (NautilusCanvasContainer *container);
 static void          process_pending_icon_to_rename                 (NautilusCanvasContainer *container);
-static void          nautilus_canvas_container_stop_monitor_top_left  (NautilusCanvasContainer *container,
-                                                                      NautilusCanvasIconData      *data,
-                                                                      gconstpointer          client);
-static void          nautilus_canvas_container_start_monitor_top_left (NautilusCanvasContainer *container,
-                                                                      NautilusCanvasIconData      *data,
-                                                                      gconstpointer          client,
-                                                                      gboolean               large_text);
 static void          handle_hadjustment_changed                     (GtkAdjustment         *adjustment,
                                                                     NautilusCanvasContainer *container);
 static void          handle_vadjustment_changed                     (GtkAdjustment         *adjustment,
@@ -5492,7 +5477,6 @@ void
 nautilus_canvas_container_clear (NautilusCanvasContainer *container)
 {
        NautilusCanvasContainerDetails *details;
-       NautilusCanvasIcon *icon;
        GList *p;
 
        g_return_if_fail (NAUTILUS_IS_CANVAS_CONTAINER (container));
@@ -5515,12 +5499,6 @@ nautilus_canvas_container_clear (NautilusCanvasContainer *container)
        details->drop_target = NULL;
 
        for (p = details->icons; p != NULL; p = p->next) {
-               icon = p->data;
-               if (icon->is_monitored) {
-                       nautilus_canvas_container_stop_monitor_top_left (container,
-                                                                        icon->data,
-                                                                        icon);
-               }
                icon_free (p->data);
        }
        g_list_free (details->icons);
@@ -5763,11 +5741,6 @@ icon_destroy (NautilusCanvasContainer *container,
                details->stretch_icon = NULL;
        }
 
-       if (icon->is_monitored) {
-               nautilus_canvas_container_stop_monitor_top_left (container,
-                                                                icon->data,
-                                                                icon);
-       }
        icon_free (icon);
 
        if (was_selected) {
@@ -5867,10 +5840,7 @@ static NautilusIconInfo *
 nautilus_canvas_container_get_icon_images (NautilusCanvasContainer *container,
                                             NautilusCanvasIconData      *data,
                                             int                    size,
-                                            char                 **embedded_text,
                                             gboolean               for_drag_accept,
-                                            gboolean               need_large_embeddded_text,
-                                            gboolean              *embedded_text_needs_loading,
                                             gboolean              *has_open_window)
 {
        NautilusCanvasContainerClass *klass;
@@ -5878,7 +5848,7 @@ nautilus_canvas_container_get_icon_images (NautilusCanvasContainer *container,
        klass = NAUTILUS_CANVAS_CONTAINER_GET_CLASS (container);
        g_assert (klass->get_icon_images != NULL);
 
-       return klass->get_icon_images (container, data, size, embedded_text, for_drag_accept, 
need_large_embeddded_text, embedded_text_needs_loading, has_open_window);
+       return klass->get_icon_images (container, data, size, for_drag_accept, has_open_window);
 }
 
 static void
@@ -5904,34 +5874,6 @@ nautilus_canvas_container_unfreeze_updates (NautilusCanvasContainer *container)
 }
 
 static void
-nautilus_canvas_container_start_monitor_top_left (NautilusCanvasContainer *container,
-                                                 NautilusCanvasIconData *data,
-                                                 gconstpointer client,
-                                                 gboolean large_text)
-{
-       NautilusCanvasContainerClass *klass;
-
-       klass = NAUTILUS_CANVAS_CONTAINER_GET_CLASS (container);
-       g_assert (klass->start_monitor_top_left != NULL);
-
-       klass->start_monitor_top_left (container, data, client, large_text);
-}
-
-static void
-nautilus_canvas_container_stop_monitor_top_left (NautilusCanvasContainer *container,
-                                                NautilusCanvasIconData *data,
-                                                gconstpointer client)
-{
-       NautilusCanvasContainerClass *klass;
-
-       klass = NAUTILUS_CANVAS_CONTAINER_GET_CLASS (container);
-       g_return_if_fail (klass->stop_monitor_top_left != NULL);
-
-       klass->stop_monitor_top_left (container, data, client);
-}
-
-
-static void
 nautilus_canvas_container_prioritize_thumbnailing (NautilusCanvasContainer *container,
                                                   NautilusCanvasIcon *icon)
 {
@@ -6033,15 +5975,8 @@ nautilus_canvas_container_update_icon (NautilusCanvasContainer *container,
        guint icon_size;
        guint min_image_size, max_image_size;
        NautilusIconInfo *icon_info;
-       GdkPoint *attach_points;
-       int n_attach_points;
-       gboolean has_embedded_text_rect;
        GdkPixbuf *pixbuf;
        char *editable_text, *additional_text;
-       char *embedded_text;
-       GdkRectangle embedded_text_rect;
-       gboolean large_embedded_text;
-       gboolean embedded_text_needs_loading;
        gboolean has_open_window;
        
        if (icon == NULL) {
@@ -6063,27 +5998,13 @@ nautilus_canvas_container_update_icon (NautilusCanvasContainer *container,
        DEBUG ("Icon size, getting for size %d", icon_size);
 
        /* Get the icons. */
-       embedded_text = NULL;
-       large_embedded_text = icon_size > ICON_SIZE_FOR_LARGE_EMBEDDED_TEXT;
        icon_info = nautilus_canvas_container_get_icon_images (container, icon->data, icon_size,
-                                                              &embedded_text,
                                                               icon == details->drop_target,                  
                                       
-                                                              large_embedded_text, 
&embedded_text_needs_loading,
                                                               &has_open_window);
 
        pixbuf = nautilus_icon_info_get_pixbuf (icon_info);
-
-       nautilus_icon_info_get_attach_points (icon_info, &attach_points, &n_attach_points);
-       has_embedded_text_rect = nautilus_icon_info_get_embedded_rect (icon_info,
-                                                                        &embedded_text_rect);
-
        g_object_unref (icon_info);
  
-       if (has_embedded_text_rect && embedded_text_needs_loading) {
-               icon->is_monitored = TRUE;
-               nautilus_canvas_container_start_monitor_top_left (container, icon->data, icon, 
large_embedded_text);
-       }
-       
        nautilus_canvas_container_get_icon_text (container,
                                                   icon->data,
                                                   &editable_text,
@@ -6108,9 +6029,6 @@ nautilus_canvas_container_update_icon (NautilusCanvasContainer *container,
                             NULL);
 
        nautilus_canvas_item_set_image (icon->item, pixbuf);
-       nautilus_canvas_item_set_attach_points (icon->item, attach_points, n_attach_points);
-       nautilus_canvas_item_set_embedded_text_rect (icon->item, &embedded_text_rect);
-       nautilus_canvas_item_set_embedded_text (icon->item, embedded_text);
 
        /* Let the pixbufs go. */
        g_object_unref (pixbuf);
diff --git a/libnautilus-private/nautilus-canvas-container.h b/libnautilus-private/nautilus-canvas-container.h
index 69db8b1..5e0d31f 100644
--- a/libnautilus-private/nautilus-canvas-container.h
+++ b/libnautilus-private/nautilus-canvas-container.h
@@ -137,10 +137,7 @@ typedef struct {
        NautilusIconInfo *(* get_icon_images)     (NautilusCanvasContainer *container,
                                                     NautilusCanvasIconData *data,
                                                     int canvas_size,
-                                                    char **embedded_text,
                                                     gboolean for_drag_accept,
-                                                    gboolean need_large_embeddded_text,
-                                                    gboolean *embedded_text_needs_loading,
                                                     gboolean *has_window_open);
        void         (* get_icon_text)            (NautilusCanvasContainer *container,
                                                     NautilusCanvasIconData *data,
@@ -157,13 +154,6 @@ typedef struct {
                                                     NautilusCanvasIconData *canvas_b);
        void         (* freeze_updates)           (NautilusCanvasContainer *container);
        void         (* unfreeze_updates)         (NautilusCanvasContainer *container);
-       void         (* start_monitor_top_left)   (NautilusCanvasContainer *container,
-                                                  NautilusCanvasIconData *data,
-                                                  gconstpointer client,
-                                                  gboolean large_text);
-       void         (* stop_monitor_top_left)    (NautilusCanvasContainer *container,
-                                                  NautilusCanvasIconData *data,
-                                                  gconstpointer client);
        void         (* prioritize_thumbnailing)  (NautilusCanvasContainer *container,
                                                   NautilusCanvasIconData *data);
 
diff --git a/libnautilus-private/nautilus-canvas-item.c b/libnautilus-private/nautilus-canvas-item.c
index 733e5b0..8bd40db 100644
--- a/libnautilus-private/nautilus-canvas-item.c
+++ b/libnautilus-private/nautilus-canvas-item.c
@@ -75,8 +75,6 @@ struct NautilusCanvasItemDetails {
        cairo_surface_t *rendered_surface;
        char *editable_text;            /* Text that can be modified by a renaming function */
        char *additional_text;          /* Text that cannot be modifed, such as file size, etc. */
-       GdkPoint *attach_points;
-       int n_attach_points;
        
        /* Size of the text at current font. */
        int text_dx;
@@ -116,13 +114,9 @@ struct NautilusCanvasItemDetails {
        
        guint is_visible : 1;
 
-       GdkRectangle embedded_text_rect;
-       char *embedded_text;
-
        /* Cached PangoLayouts. Only used if the icon is visible */
        PangoLayout *editable_text_layout;
        PangoLayout *additional_text_layout;
-       PangoLayout *embedded_text_layout;
 
        /* Cached rectangle in canvas coordinates */
        EelIRect icon_rect;
@@ -212,7 +206,6 @@ nautilus_canvas_item_finalize (GObject *object)
 
        g_free (details->editable_text);
        g_free (details->additional_text);
-       g_free (details->attach_points);
 
        if (details->rendered_surface != NULL) {
                cairo_surface_destroy (details->rendered_surface);
@@ -226,12 +219,6 @@ nautilus_canvas_item_finalize (GObject *object)
                g_object_unref (details->additional_text_layout);
        }
 
-       if (details->embedded_text_layout != NULL) {
-               g_object_unref (details->embedded_text_layout);
-       }
-
-       g_free (details->embedded_text);
-
        G_OBJECT_CLASS (nautilus_canvas_item_parent_class)->finalize (object);
 }
  
@@ -266,9 +253,6 @@ nautilus_canvas_item_invalidate_label_size (NautilusCanvasItem *item)
        if (item->details->additional_text_layout != NULL) {
                pango_layout_context_changed (item->details->additional_text_layout);
        }
-       if (item->details->embedded_text_layout != NULL) {
-               pango_layout_context_changed (item->details->embedded_text_layout);
-       }
        nautilus_canvas_item_invalidate_bounds_cache (item);
        item->details->text_width = -1;
        item->details->text_height = -1;
@@ -471,52 +455,6 @@ nautilus_canvas_item_set_image (NautilusCanvasItem *item,
        eel_canvas_item_request_update (EEL_CANVAS_ITEM (item));        
 }
 
-void 
-nautilus_canvas_item_set_attach_points (NautilusCanvasItem *item,
-                                       GdkPoint *attach_points,
-                                       int n_attach_points)
-{
-       g_free (item->details->attach_points);
-       item->details->attach_points = NULL;
-       item->details->n_attach_points = 0;
-
-       if (attach_points != NULL && n_attach_points != 0) {
-               item->details->attach_points = g_memdup (attach_points, n_attach_points * sizeof (GdkPoint));
-               item->details->n_attach_points = n_attach_points;
-       }
-       
-       nautilus_canvas_item_invalidate_bounds_cache (item);
-}
-
-void
-nautilus_canvas_item_set_embedded_text_rect (NautilusCanvasItem       *item,
-                                            const GdkRectangle           *text_rect)
-{
-       item->details->embedded_text_rect = *text_rect;
-
-       nautilus_canvas_item_invalidate_bounds_cache (item);
-       eel_canvas_item_request_update (EEL_CANVAS_ITEM (item));
-}
-
-void
-nautilus_canvas_item_set_embedded_text (NautilusCanvasItem       *item,
-                                       const char                   *text)
-{
-       g_free (item->details->embedded_text);
-       item->details->embedded_text = g_strdup (text);
-
-       if (item->details->embedded_text_layout != NULL) {
-               if (text != NULL) {
-                       pango_layout_set_text (item->details->embedded_text_layout, text, -1);
-               } else {
-                       pango_layout_set_text (item->details->embedded_text_layout, "", -1);
-               }
-       }
-
-       eel_canvas_item_request_update (EEL_CANVAS_ITEM (item));
-}
-
-
 /* Recomputes the bounding box of a canvas item.
  * This is a generic implementation that could be used for any canvas item
  * class, it has no assumptions about how the item is used.
@@ -1103,14 +1041,8 @@ nautilus_canvas_item_invalidate_label (NautilusCanvasItem     *item)
                g_object_unref (item->details->additional_text_layout);
                item->details->additional_text_layout = NULL;
        }
-
-       if (item->details->embedded_text_layout) {
-               g_object_unref (item->details->embedded_text_layout);
-               item->details->embedded_text_layout = NULL;
-       }
 }
 
-
 static GdkPixbuf *
 get_knob_pixbuf (void)
 {
@@ -1260,63 +1192,6 @@ map_surface (NautilusCanvasItem *canvas_item)
        return canvas_item->details->rendered_surface;
 }
 
-static void
-draw_embedded_text (NautilusCanvasItem *item,
-                    cairo_t *cr,
-                   int x, int y)
-{
-       PangoLayout *layout;
-       PangoContext *context;
-       PangoFontDescription *desc;
-       GtkWidget *widget;
-       GtkStyleContext *style_context;
-
-       if (item->details->embedded_text == NULL ||
-           item->details->embedded_text_rect.width == 0 ||
-           item->details->embedded_text_rect.height == 0) {
-               return;
-       }
-
-       widget = GTK_WIDGET (EEL_CANVAS_ITEM (item)->canvas);
-
-       if (item->details->embedded_text_layout != NULL) {
-               layout = g_object_ref (item->details->embedded_text_layout);
-       } else {
-               context = gtk_widget_get_pango_context (widget);
-               layout = pango_layout_new (context);
-               pango_layout_set_text (layout, item->details->embedded_text, -1);
-               
-               desc = pango_font_description_from_string ("monospace 6");
-               pango_layout_set_font_description (layout, desc);
-               pango_font_description_free (desc);
-
-               if (item->details->is_visible) {
-                       item->details->embedded_text_layout = g_object_ref (layout);
-               }
-       }
-
-       style_context = gtk_widget_get_style_context (widget);
-       gtk_style_context_save (style_context);
-       gtk_style_context_add_class (style_context, "icon-embedded-text");
-
-       cairo_save (cr);
-
-       cairo_rectangle (cr,
-                        x + item->details->embedded_text_rect.x,
-                        y + item->details->embedded_text_rect.y,
-                        item->details->embedded_text_rect.width,
-                        item->details->embedded_text_rect.height);
-       cairo_clip (cr);
-
-       gtk_render_layout (style_context, cr,
-                          x + item->details->embedded_text_rect.x,
-                          y + item->details->embedded_text_rect.y,
-                          layout);
-
-       gtk_style_context_restore (style_context);
-       cairo_restore (cr);
-}
-
 cairo_surface_t *
 nautilus_canvas_item_get_drag_surface (NautilusCanvasItem *item)
 {
@@ -1371,8 +1246,6 @@ nautilus_canvas_item_get_drag_surface (NautilusCanvasItem *item)
        icon_rect.x1 = item_offset_x + pix_width;
        icon_rect.y1 = item_offset_y + pix_height;
 
-       draw_embedded_text (item, cr,
-                           item_offset_x, item_offset_y);
        draw_label_text (item, cr, icon_rect);
        cairo_destroy (cr);
 
@@ -1415,8 +1288,6 @@ nautilus_canvas_item_draw (EelCanvasItem *item,
                                 icon_rect.x0, icon_rect.y0);
        cairo_surface_destroy (temp_surface);
 
-       draw_embedded_text (canvas_item, cr, icon_rect.x0, icon_rect.y0);
-       
        /* Draw stretching handles (if necessary). */
        draw_stretch_handles (canvas_item, cr, &icon_rect);
        
diff --git a/libnautilus-private/nautilus-canvas-item.h b/libnautilus-private/nautilus-canvas-item.h
index bf98bea..9daba19 100644
--- a/libnautilus-private/nautilus-canvas-item.h
+++ b/libnautilus-private/nautilus-canvas-item.h
@@ -72,13 +72,6 @@ void        nautilus_canvas_item_set_emblems              (NautilusCanvasItem
                                                           GList                    *emblem_pixbufs);
 void        nautilus_canvas_item_set_show_stretch_handles (NautilusCanvasItem       *item,
                                                           gboolean                  show_stretch_handles);
-void        nautilus_canvas_item_set_attach_points        (NautilusCanvasItem       *item,
-                                                          GdkPoint                 *attach_points,
-                                                          int                       n_attach_points);
-void        nautilus_canvas_item_set_embedded_text_rect   (NautilusCanvasItem       *item,
-                                                          const GdkRectangle       *text_rect);
-void        nautilus_canvas_item_set_embedded_text        (NautilusCanvasItem       *item,
-                                                          const char               *text);
 double      nautilus_canvas_item_get_max_text_width       (NautilusCanvasItem       *item);
 const char *nautilus_canvas_item_get_editable_text        (NautilusCanvasItem       *canvas_item);
 void        nautilus_canvas_item_set_renaming             (NautilusCanvasItem       *canvas_item,
diff --git a/libnautilus-private/nautilus-canvas-private.h b/libnautilus-private/nautilus-canvas-private.h
index 9dab8cb..8a79120 100644
--- a/libnautilus-private/nautilus-canvas-private.h
+++ b/libnautilus-private/nautilus-canvas-private.h
@@ -61,9 +61,6 @@ typedef struct {
        /* Whether this item is visible in the view. */
        eel_boolean_bit is_visible : 1;
 
-       /* Whether a monitor was set on this icon. */
-       eel_boolean_bit is_monitored : 1;
-
        eel_boolean_bit has_lazy_position : 1;
 } NautilusCanvasIcon;
 
diff --git a/libnautilus-private/nautilus-directory-async.c b/libnautilus-private/nautilus-directory-async.c
index c7bd86b..251081f 100644
--- a/libnautilus-private/nautilus-directory-async.c
+++ b/libnautilus-private/nautilus-directory-async.c
@@ -508,18 +508,6 @@ mime_list_cancel (NautilusDirectory *directory)
 }
 
 static void
-top_left_cancel (NautilusDirectory *directory)
-{
-       if (directory->details->top_left_read_state != NULL) {
-               g_cancellable_cancel (directory->details->top_left_read_state->cancellable);
-               directory->details->top_left_read_state->directory = NULL;
-               directory->details->top_left_read_state = NULL;
-               
-               async_job_end (directory, "top left");
-       }
-}
-
-static void
 link_info_cancel (NautilusDirectory *directory)
 {
        if (directory->details->link_info_read_state != NULL) {
@@ -675,16 +663,6 @@ nautilus_directory_set_up_request (NautilusFileAttributes file_attributes)
                REQUEST_SET_TYPE (request, REQUEST_FILE_INFO);
                REQUEST_SET_TYPE (request, REQUEST_LINK_INFO);
        }
-       
-       if (file_attributes & NAUTILUS_FILE_ATTRIBUTE_TOP_LEFT_TEXT) {
-               REQUEST_SET_TYPE (request, REQUEST_TOP_LEFT_TEXT);
-               REQUEST_SET_TYPE (request, REQUEST_FILE_INFO);
-       }
-       
-       if (file_attributes & NAUTILUS_FILE_ATTRIBUTE_LARGE_TOP_LEFT_TEXT) {
-               REQUEST_SET_TYPE (request, REQUEST_LARGE_TOP_LEFT_TEXT);
-               REQUEST_SET_TYPE (request, REQUEST_FILE_INFO);
-       }
 
        if ((file_attributes & NAUTILUS_FILE_ATTRIBUTE_EXTENSION_INFO) != 0) {
                REQUEST_SET_TYPE (request, REQUEST_EXTENSION_INFO);
@@ -1576,11 +1554,6 @@ nautilus_async_destroying_file (NautilusFile *file)
                directory->details->get_info_file = NULL;
                changed = TRUE;
        }
-       if (directory->details->top_left_read_state != NULL
-           && directory->details->top_left_read_state->file == file) {
-               directory->details->top_left_read_state->file = NULL;
-               changed = TRUE;
-       }
        if (directory->details->link_info_read_state != NULL &&
            directory->details->link_info_read_state->file == file) {
                directory->details->link_info_read_state->file = NULL;
@@ -1630,22 +1603,6 @@ should_get_directory_count_now (NautilusFile *file)
 }
 
 static gboolean
-lacks_top_left (NautilusFile *file)
-{
-       return file->details->file_info_is_up_to_date &&
-               !file->details->top_left_text_is_up_to_date 
-               && nautilus_file_should_get_top_left_text (file);
-}
-
-static gboolean
-lacks_large_top_left (NautilusFile *file)
-{
-       return file->details->file_info_is_up_to_date &&
-               (!file->details->top_left_text_is_up_to_date ||
-                file->details->got_large_top_left_text != file->details->got_top_left_text)
-               && nautilus_file_should_get_top_left_text (file);
-}
-static gboolean
 lacks_info (NautilusFile *file)
 {
        return !file->details->file_info_is_up_to_date
@@ -1773,18 +1730,6 @@ request_is_satisfied (NautilusDirectory *directory,
                }
        }
 
-       if (REQUEST_WANTS_TYPE (request, REQUEST_TOP_LEFT_TEXT)) {
-               if (has_problem (directory, file, lacks_top_left)) {
-                       return FALSE;
-               }
-       }
-               
-       if (REQUEST_WANTS_TYPE (request, REQUEST_LARGE_TOP_LEFT_TEXT)) {
-               if (has_problem (directory, file, lacks_large_top_left)) {
-                       return FALSE;
-               }
-       }
-
        if (REQUEST_WANTS_TYPE (request, REQUEST_DEEP_COUNT)) {
                if (has_problem (directory, file, lacks_deep_count)) {
                        return FALSE;
@@ -3144,185 +3089,6 @@ mime_list_start (NautilusDirectory *directory,
 }
 
 static void
-top_left_stop (NautilusDirectory *directory)
-{
-       NautilusFile *file;
-
-       if (directory->details->top_left_read_state != NULL) {
-               file = directory->details->top_left_read_state->file;
-               if (file != NULL) {
-                       g_assert (NAUTILUS_IS_FILE (file));
-                       g_assert (file->details->directory == directory);
-                       if (is_needy (file,
-                                     lacks_top_left,
-                                     REQUEST_TOP_LEFT_TEXT) ||
-                           is_needy (file,
-                                     lacks_large_top_left,
-                                     REQUEST_LARGE_TOP_LEFT_TEXT)) {
-                               return;
-                       }
-               }
-
-               /* The top left is not wanted, so stop it. */
-               top_left_cancel (directory);
-       }
-}
-
-static void
-top_left_read_state_free (TopLeftTextReadState *state)
-{
-       g_object_unref (state->cancellable);
-       g_free (state);
-}
-
-static void
-top_left_read_callback (GObject *source_object,
-                       GAsyncResult *res,
-                       gpointer callback_data)
-{
-       TopLeftTextReadState *state;
-       NautilusDirectory *directory;
-       NautilusFileDetails *file_details;
-       gsize file_size;
-       char *file_contents;
-
-       state = callback_data;
-
-       if (state->directory == NULL) {
-               /* Operation was cancelled. Bail out */
-               top_left_read_state_free (state);
-               return;
-       }
-       
-       directory = nautilus_directory_ref (state->directory);
-       
-       file_details = state->file->details;
-
-       file_details->top_left_text_is_up_to_date = TRUE;
-       g_free (file_details->top_left_text);
-
-       if (g_file_load_partial_contents_finish (G_FILE (source_object),
-                                                res,
-                                                &file_contents, &file_size,
-                                                NULL, NULL)) {
-               file_details->top_left_text = nautilus_extract_top_left_text (file_contents, state->large, 
file_size);
-               file_details->got_top_left_text = TRUE;
-               file_details->got_large_top_left_text = state->large;
-               g_free (file_contents);
-       } else {
-               file_details->top_left_text = NULL;
-               file_details->got_top_left_text = FALSE;
-               file_details->got_large_top_left_text = FALSE;
-       }
-
-       nautilus_file_changed (state->file);
-
-       directory->details->top_left_read_state = NULL;
-       async_job_end (directory, "top left");
-
-       top_left_read_state_free (state);
-       
-       nautilus_directory_async_state_changed (directory);
-
-       nautilus_directory_unref (directory);
-}
-
-static int
-count_lines (const char *text, int length)
-{
-       int count, i;
-
-       count = 0;
-       for (i = 0; i < length; i++) {
-               count += *text++ == '\n';
-       }
-       return count;
-}
-
-static gboolean
-top_left_read_more_callback (const char *file_contents,
-                            goffset bytes_read,
-                            gpointer callback_data)
-{
-       TopLeftTextReadState *state;
-
-       state = callback_data;
-
-       /* Stop reading when we have enough. */
-       if (state->large) {
-               return bytes_read < NAUTILUS_FILE_LARGE_TOP_LEFT_TEXT_MAXIMUM_BYTES &&
-                       count_lines (file_contents, bytes_read) <= 
NAUTILUS_FILE_LARGE_TOP_LEFT_TEXT_MAXIMUM_LINES;
-       } else {
-               return bytes_read < NAUTILUS_FILE_TOP_LEFT_TEXT_MAXIMUM_BYTES &&
-                       count_lines (file_contents, bytes_read) <= NAUTILUS_FILE_TOP_LEFT_TEXT_MAXIMUM_LINES;
-       }
-}
-
-static void
-top_left_start (NautilusDirectory *directory,
-               NautilusFile *file,
-               gboolean *doing_io)
-{
-       GFile *location;
-       gboolean needs_large;
-       TopLeftTextReadState *state;
-
-       if (directory->details->top_left_read_state != NULL) {
-               *doing_io = TRUE;
-               return;
-       }
-       
-       needs_large = FALSE;
-
-       if (is_needy (file,
-                     lacks_large_top_left,
-                     REQUEST_LARGE_TOP_LEFT_TEXT)) {
-               needs_large = TRUE;
-       }
-
-       /* Figure out which file to read the top left for. */
-       if (!(needs_large ||
-             is_needy (file,
-                       lacks_top_left,
-                       REQUEST_TOP_LEFT_TEXT))) {
-               return;
-       }
-       *doing_io = TRUE;
-
-       if (!nautilus_file_contains_text (file)) {
-               g_free (file->details->top_left_text);
-               file->details->top_left_text = NULL;
-               file->details->got_top_left_text = FALSE;
-               file->details->got_large_top_left_text = FALSE;
-               file->details->top_left_text_is_up_to_date = TRUE;
-
-               nautilus_directory_async_state_changed (directory);
-               return;
-       }
-
-       if (!async_job_start (directory, "top left")) {
-               return;
-       }
-
-       /* Start reading. */
-       state = g_new0 (TopLeftTextReadState, 1);
-       state->directory = directory;
-       state->cancellable = g_cancellable_new ();
-       state->large = needs_large;
-       state->file = file;
-
-       directory->details->top_left_read_state = state;
-
-       location = nautilus_file_get_location (file);
-       g_file_load_partial_contents_async (location,
-                                           state->cancellable,
-                                           top_left_read_more_callback,
-                                           top_left_read_callback,
-                                           state);
-       g_object_unref (location);
-}
-
-static void
 get_info_state_free (GetInfoState *state)
 {
        g_object_unref (state->cancellable);
@@ -4446,7 +4212,6 @@ start_or_stop_io (NautilusDirectory *directory)
        directory_count_stop (directory);
        deep_count_stop (directory);
        mime_list_stop (directory);
-       top_left_stop (directory);
        link_info_stop (directory);
        extension_info_stop (directory);
        mount_stop (directory);
@@ -4478,7 +4243,6 @@ start_or_stop_io (NautilusDirectory *directory)
                directory_count_start (directory, file, &doing_io);
                deep_count_start (directory, file, &doing_io);
                mime_list_start (directory, file, &doing_io);
-               top_left_start (directory, file, &doing_io);
                thumbnail_start (directory, file, &doing_io);
                filesystem_info_start (directory, file, &doing_io);
 
@@ -4548,7 +4312,6 @@ nautilus_directory_cancel (NautilusDirectory *directory)
        link_info_cancel (directory);
        mime_list_cancel (directory);
        new_files_cancel (directory);
-       top_left_cancel (directory);
        extension_info_cancel (directory);
        thumbnail_cancel (directory);
        mount_cancel (directory);
@@ -4593,16 +4356,6 @@ cancel_mime_list_for_file (NautilusDirectory *directory,
 }
 
 static void
-cancel_top_left_text_for_file (NautilusDirectory *directory,
-                              NautilusFile      *file)
-{
-       if (directory->details->top_left_read_state != NULL &&
-           directory->details->top_left_read_state->file == file) {
-               top_left_cancel (directory);
-       }
-}
-
-static void
 cancel_file_info_for_file (NautilusDirectory *directory,
                           NautilusFile      *file)
 {
@@ -4669,9 +4422,6 @@ cancel_loading_attributes (NautilusDirectory *directory,
        if (REQUEST_WANTS_TYPE (request, REQUEST_MIME_LIST)) {
                mime_list_cancel (directory);
        }
-       if (REQUEST_WANTS_TYPE (request, REQUEST_TOP_LEFT_TEXT)) {
-               top_left_cancel (directory);
-       }
        if (REQUEST_WANTS_TYPE (request, REQUEST_FILE_INFO)) {
                file_info_cancel (directory);
        }
@@ -4717,9 +4467,6 @@ nautilus_directory_cancel_loading_file_attributes (NautilusDirectory      *direc
        if (REQUEST_WANTS_TYPE (request, REQUEST_MIME_LIST)) {
                cancel_mime_list_for_file (directory, file);
        }
-       if (REQUEST_WANTS_TYPE (request, REQUEST_TOP_LEFT_TEXT)) {
-               cancel_top_left_text_for_file (directory, file);
-       }
        if (REQUEST_WANTS_TYPE (request, REQUEST_FILE_INFO)) {
                cancel_file_info_for_file (directory, file);
        }
diff --git a/libnautilus-private/nautilus-directory-private.h 
b/libnautilus-private/nautilus-directory-private.h
index 7fd092b..c1cbaf0 100644
--- a/libnautilus-private/nautilus-directory-private.h
+++ b/libnautilus-private/nautilus-directory-private.h
@@ -49,8 +49,6 @@ typedef enum {
        REQUEST_FILE_INFO,
        REQUEST_FILE_LIST, /* always FALSE if file != NULL */
        REQUEST_MIME_LIST,
-       REQUEST_TOP_LEFT_TEXT,
-       REQUEST_LARGE_TOP_LEFT_TEXT,
        REQUEST_EXTENSION_INFO,
        REQUEST_THUMBNAIL,
        REQUEST_MOUNT,
@@ -127,8 +125,6 @@ struct NautilusDirectoryDetails
 
        FilesystemInfoState *filesystem_info_state;
        
-       TopLeftTextReadState *top_left_read_state;
-
        LinkInfoReadState *link_info_read_state;
 
        GList *file_operations_in_progress; /* list of FileOperation * */
diff --git a/libnautilus-private/nautilus-directory.c b/libnautilus-private/nautilus-directory.c
index 8239cbe..9b94c26 100644
--- a/libnautilus-private/nautilus-directory.c
+++ b/libnautilus-private/nautilus-directory.c
@@ -206,7 +206,6 @@ nautilus_directory_finalize (GObject *object)
 
        nautilus_directory_cancel (directory);
        g_assert (directory->details->count_in_progress == NULL);
-       g_assert (directory->details->top_left_read_state == NULL);
 
        if (directory->details->monitor_list != NULL) {
                g_warning ("destroying a NautilusDirectory while it's being monitored");
@@ -1114,7 +1113,6 @@ nautilus_directory_notify_files_changed (GList *files)
                         * a changed signal.
                         */
                        file->details->file_info_is_up_to_date = FALSE;
-                       file->details->top_left_text_is_up_to_date = FALSE;
                        file->details->link_info_is_up_to_date = FALSE;
                        nautilus_file_invalidate_extension_info_internal (file);
 
diff --git a/libnautilus-private/nautilus-file-private.h b/libnautilus-private/nautilus-file-private.h
index 535615c..b64f38f 100644
--- a/libnautilus-private/nautilus-file-private.h
+++ b/libnautilus-private/nautilus-file-private.h
@@ -30,14 +30,6 @@
 #include <eel/eel-glib-extensions.h>
 #include <eel/eel-string.h>
 
-#define NAUTILUS_FILE_LARGE_TOP_LEFT_TEXT_MAXIMUM_CHARACTERS_PER_LINE 80
-#define NAUTILUS_FILE_LARGE_TOP_LEFT_TEXT_MAXIMUM_LINES               24
-#define NAUTILUS_FILE_LARGE_TOP_LEFT_TEXT_MAXIMUM_BYTES               10000
-
-#define NAUTILUS_FILE_TOP_LEFT_TEXT_MAXIMUM_CHARACTERS_PER_LINE 10
-#define NAUTILUS_FILE_TOP_LEFT_TEXT_MAXIMUM_LINES               5
-#define NAUTILUS_FILE_TOP_LEFT_TEXT_MAXIMUM_BYTES               1024
-
 #define NAUTILUS_FILE_DEFAULT_ATTRIBUTES                               \
        
"standard::*,access::*,mountable::*,time::*,unix::*,owner::*,selinux::*,thumbnail::*,id::filesystem,trash::orig-path,trash::deletion-date,metadata::*"
 
@@ -101,7 +93,6 @@ struct NautilusFileDetails
        time_t thumbnail_mtime;
        
        GList *mime_list; /* If this is a directory, the list of MIME types in it. */
-       char *top_left_text;
 
        /* Info you might get from a link (.desktop, .directory or nautilus link) */
        GIcon *custom_icon;
@@ -168,10 +159,6 @@ struct NautilusFileDetails
 
        eel_boolean_bit mount_is_up_to_date           : 1;
        
-       eel_boolean_bit got_top_left_text             : 1;
-       eel_boolean_bit got_large_top_left_text       : 1;
-       eel_boolean_bit top_left_text_is_up_to_date   : 1;
-
        eel_boolean_bit got_link_info                 : 1;
        eel_boolean_bit link_info_is_up_to_date       : 1;
        eel_boolean_bit got_custom_display_name       : 1;
@@ -240,9 +227,6 @@ NautilusFile *nautilus_file_new_from_info                  (NautilusDirectory
                                                            GFileInfo              *info);
 void          nautilus_file_emit_changed                   (NautilusFile           *file);
 void          nautilus_file_mark_gone                      (NautilusFile           *file);
-char *        nautilus_extract_top_left_text               (const char             *text,
-                                                           gboolean                large,
-                                                           int                     length);
 void          nautilus_file_set_directory                  (NautilusFile           *file,
                                                            NautilusDirectory      *directory);
 gboolean      nautilus_file_get_date                       (NautilusFile           *file,
@@ -273,11 +257,6 @@ gboolean      nautilus_file_set_display_name               (NautilusFile
 void          nautilus_file_set_mount                      (NautilusFile           *file,
                                                            GMount                 *mount);
 
-/* Return true if the top lefts of files in this directory should be
- * fetched, according to the preference settings.
- */
-gboolean      nautilus_file_should_get_top_left_text       (NautilusFile           *file);
-
 /* Mark specified attributes for this file out of date without canceling current
  * I/O or kicking off new I/O.
  */
diff --git a/libnautilus-private/nautilus-file.c b/libnautilus-private/nautilus-file.c
index 6c94987..5fa0157 100644
--- a/libnautilus-private/nautilus-file.c
+++ b/libnautilus-private/nautilus-file.c
@@ -798,7 +798,6 @@ finalize (GObject *object)
        eel_ref_str_unref (file->details->group);
        g_free (file->details->selinux_context);
        g_free (file->details->description);
-       g_free (file->details->top_left_text);
        g_free (file->details->activation_uri);
        g_clear_object (&file->details->custom_icon);
 
@@ -4609,22 +4608,6 @@ nautilus_file_should_show_type (NautilusFile *file)
        return ret;
 }
 
-gboolean
-nautilus_file_should_get_top_left_text (NautilusFile *file)
-{
-       g_return_val_if_fail (NAUTILUS_IS_FILE (file), FALSE);
-
-       if (show_file_thumbs == NAUTILUS_SPEED_TRADEOFF_ALWAYS) {
-               return TRUE;
-       }
-       
-       if (show_file_thumbs == NAUTILUS_SPEED_TRADEOFF_NEVER) {
-               return FALSE;
-       }
-
-       return get_speed_tradeoff_preference_for_file (file, show_file_thumbs);
-}
-
 /**
  * nautilus_file_get_directory_item_count
  * 
@@ -7007,66 +6990,6 @@ nautilus_file_is_executable (NautilusFile *file)
        return file->details->can_execute;
 }
 
-/**
- * nautilus_file_peek_top_left_text
- * 
- * Peek at the text from the top left of the file.
- * @file: NautilusFile representing the file in question.
- * 
- * Returns: NULL if there is no text readable, otherwise, the text.
- *          This string is owned by the file object and should not
- *          be kept around or freed.
- * 
- **/
-char *
-nautilus_file_peek_top_left_text (NautilusFile *file,
-                                 gboolean  need_large_text,
-                                 gboolean *needs_loading)
-{
-       g_return_val_if_fail (NAUTILUS_IS_FILE (file), NULL);
-
-       if (!nautilus_file_should_get_top_left_text (file)) {
-               if (needs_loading) {
-                       *needs_loading = FALSE;
-               }
-               return NULL;
-       }
-       
-       if (needs_loading) {
-               *needs_loading = !file->details->top_left_text_is_up_to_date;
-               if (need_large_text) {
-                       *needs_loading |= file->details->got_top_left_text != 
file->details->got_large_top_left_text;
-               }
-       }
-
-       /* Show " ..." in the file until we read the contents in. */
-       if (!file->details->got_top_left_text) {
-               
-               if (nautilus_file_contains_text (file)) {
-                       return " ...";
-               }
-               return NULL;
-       }
-       
-       /* Show what we read in. */
-       return file->details->top_left_text;
-}
-
-/**
- * nautilus_file_get_top_left_text
- * 
- * Get the text from the top left of the file.
- * @file: NautilusFile representing the file in question.
- * 
- * Returns: NULL if there is no text readable, otherwise, the text.
- * 
- **/
-char *
-nautilus_file_get_top_left_text (NautilusFile *file)
-{
-       return g_strdup (nautilus_file_peek_top_left_text (file, FALSE, NULL));
-}
-
 char *
 nautilus_file_get_filesystem_id (NautilusFile *file)
 {
@@ -7316,12 +7239,6 @@ invalidate_mime_list (NautilusFile *file)
 }
 
 static void
-invalidate_top_left_text (NautilusFile *file)
-{
-       file->details->top_left_text_is_up_to_date = FALSE;
-}
-
-static void
 invalidate_file_info (NautilusFile *file)
 {
        file->details->file_info_is_up_to_date = FALSE;
@@ -7387,9 +7304,6 @@ nautilus_file_invalidate_attributes_internal (NautilusFile *file,
        if (REQUEST_WANTS_TYPE (request, REQUEST_FILE_INFO)) {
                invalidate_file_info (file);
        }
-       if (REQUEST_WANTS_TYPE (request, REQUEST_TOP_LEFT_TEXT)) {
-               invalidate_top_left_text (file);
-       }
        if (REQUEST_WANTS_TYPE (request, REQUEST_LINK_INFO)) {
                invalidate_link_info (file);
        }
@@ -7477,8 +7391,6 @@ nautilus_file_get_all_attributes (void)
                NAUTILUS_FILE_ATTRIBUTE_DEEP_COUNTS |
                NAUTILUS_FILE_ATTRIBUTE_DIRECTORY_ITEM_COUNT | 
                NAUTILUS_FILE_ATTRIBUTE_DIRECTORY_ITEM_MIME_TYPES | 
-               NAUTILUS_FILE_ATTRIBUTE_TOP_LEFT_TEXT | 
-               NAUTILUS_FILE_ATTRIBUTE_LARGE_TOP_LEFT_TEXT |
                NAUTILUS_FILE_ATTRIBUTE_EXTENSION_INFO |
                NAUTILUS_FILE_ATTRIBUTE_THUMBNAIL |
                NAUTILUS_FILE_ATTRIBUTE_MOUNT;
@@ -7852,136 +7764,6 @@ nautilus_file_list_cancel_call_when_ready (NautilusFileListHandle *handle)
        }
 }
 
-static char *
-try_to_make_utf8 (const char *text, int *length)
-{
-       static const char *encodings_to_try[2];
-       static int n_encodings_to_try = 0;
-        gsize converted_length;
-        GError *conversion_error;
-       char *utf8_text;
-       int i;
-       
-       if (n_encodings_to_try == 0) {
-               const char *charset;
-               gboolean charset_is_utf8;
-               
-               charset_is_utf8 = g_get_charset (&charset);
-               if (!charset_is_utf8) {
-                       encodings_to_try[n_encodings_to_try++] = charset;
-               }
-        
-               if (g_ascii_strcasecmp (charset, "ISO-8859-1") != 0) {
-                       encodings_to_try[n_encodings_to_try++] = "ISO-8859-1";
-               }
-       }
-
-        utf8_text = NULL;
-       for (i = 0; i < n_encodings_to_try; i++) {
-               conversion_error = NULL;
-               utf8_text = g_convert (text, *length, 
-                                          "UTF-8", encodings_to_try[i],
-                                          NULL, &converted_length, &conversion_error);
-               if (utf8_text != NULL) {
-                       *length = converted_length;
-                       break;
-               }
-               g_error_free (conversion_error);
-       }
-       
-       return utf8_text;
-}
-
-
-
-/* Extract the top left part of the read-in text. */
-char *
-nautilus_extract_top_left_text (const char *text,
-                               gboolean large,
-                               int length)
-{
-        GString* buffer;
-       const gchar *in;
-       const gchar *end;
-       int line, i;
-       gunichar c;
-       char *text_copy;
-       const char *utf8_end;
-       gboolean validated;
-       int max_bytes, max_lines, max_cols;
-
-       if (large) {
-               max_bytes = NAUTILUS_FILE_LARGE_TOP_LEFT_TEXT_MAXIMUM_BYTES;
-               max_lines = NAUTILUS_FILE_LARGE_TOP_LEFT_TEXT_MAXIMUM_LINES;
-               max_cols = NAUTILUS_FILE_LARGE_TOP_LEFT_TEXT_MAXIMUM_CHARACTERS_PER_LINE;
-       } else {
-               max_bytes = NAUTILUS_FILE_TOP_LEFT_TEXT_MAXIMUM_BYTES;
-               max_lines = NAUTILUS_FILE_TOP_LEFT_TEXT_MAXIMUM_LINES;
-               max_cols = NAUTILUS_FILE_TOP_LEFT_TEXT_MAXIMUM_CHARACTERS_PER_LINE;
-       }
-                       
-       
-
-        text_copy = NULL;
-        if (text != NULL) {
-               /* Might be a partial utf8 character at the end if we didn't read whole file */
-               validated = g_utf8_validate (text, length, &utf8_end);
-               if (!validated &&
-                   !(length >= max_bytes &&
-                     text + length - utf8_end < 6)) {
-                       text_copy = try_to_make_utf8 (text, &length);
-                       text = text_copy;
-               } else if (!validated) {
-                       length = utf8_end - text;
-               }
-        }
-
-       if (text == NULL || length == 0) {
-               return NULL;
-       }
-
-       buffer = g_string_new ("");
-       end = text + length; in = text;
-
-       for (line = 0; line < max_lines; line++) {
-               /* Extract one line. */
-               for (i = 0; i < max_cols; ) {
-                       if (*in == '\n') {
-                               break;
-                       }
-                       
-                       c = g_utf8_get_char (in);
-                       
-                       if (g_unichar_isprint (c)) {
-                               g_string_append_unichar (buffer, c);
-                               i++;
-                       }
-                       
-                       in = g_utf8_next_char (in);
-                       if (in == end) {
-                               goto done;
-                       }
-               }
-
-               /* Skip the rest of the line. */
-               while (*in != '\n') {
-                       if (++in == end) {
-                               goto done;
-                       }
-               }
-               if (++in == end) {
-                       goto done;
-               }
-
-               /* Put a new-line separator in. */
-               g_string_append_c(buffer, '\n');
-       }
- done:
-       g_free (text_copy);
-
-       return g_string_free(buffer, FALSE);
-}
-
 static void
 thumbnail_limit_changed_callback (gpointer user_data)
 {
diff --git a/libnautilus-private/nautilus-file.h b/libnautilus-private/nautilus-file.h
index 3fe5e4f..90294f0 100644
--- a/libnautilus-private/nautilus-file.h
+++ b/libnautilus-private/nautilus-file.h
@@ -210,10 +210,6 @@ gboolean                nautilus_file_should_show_thumbnail             (Nautilu
 gboolean                nautilus_file_should_show_directory_item_count  (NautilusFile                   
*file);
 gboolean                nautilus_file_should_show_type                  (NautilusFile                   
*file);
 GList *                 nautilus_file_get_emblem_icons                  (NautilusFile                   
*file);
-char *                  nautilus_file_get_top_left_text                 (NautilusFile                   
*file);
-char *                  nautilus_file_peek_top_left_text                (NautilusFile                   
*file,
-                                                                        gboolean                        
need_large_text,
-                                                                        gboolean                       
*got_top_left_text);
 gboolean                nautilus_file_get_directory_item_mime_types     (NautilusFile                   
*file,
                                                                         GList                         
**mime_list);
 
diff --git a/libnautilus-private/nautilus-icon-info.c b/libnautilus-private/nautilus-icon-info.c
index 8a17d64..c272803 100644
--- a/libnautilus-private/nautilus-icon-info.c
+++ b/libnautilus-private/nautilus-icon-info.c
@@ -32,11 +32,6 @@ struct _NautilusIconInfo
        gint64 last_use_time;
        GdkPixbuf *pixbuf;
        
-       gboolean got_embedded_rect;
-       GdkRectangle embedded_rect;
-       gint n_attach_points;
-       GdkPoint *attach_points;
-       char *display_name;
         char *icon_name;
 
        gint  orig_scale;
@@ -99,8 +94,6 @@ nautilus_icon_info_finalize (GObject *object)
        if (icon->pixbuf) {
                g_object_unref (icon->pixbuf);
        }
-       g_free (icon->attach_points);
-       g_free (icon->display_name);
        g_free (icon->icon_name);
 
         G_OBJECT_CLASS (nautilus_icon_info_parent_class)->finalize (object);
@@ -139,8 +132,6 @@ nautilus_icon_info_new_for_icon_info (GtkIconInfo *icon_info,
                                      gint         scale)
 {
        NautilusIconInfo *icon;
-       GdkPoint *points;
-       gint n_points;
        const char *filename;
        char *basename, *p;
 
@@ -148,16 +139,6 @@ nautilus_icon_info_new_for_icon_info (GtkIconInfo *icon_info,
 
        icon->pixbuf = gtk_icon_info_load_icon (icon_info, NULL);
 
-       icon->got_embedded_rect = gtk_icon_info_get_embedded_rect (icon_info,
-                                                                  &icon->embedded_rect);
-
-       if (gtk_icon_info_get_attach_points (icon_info, &points, &n_points)) {
-               icon->n_attach_points = n_points;
-               icon->attach_points = points;
-       }
-
-       icon->display_name = g_strdup (gtk_icon_info_get_display_name (icon_info));
-
        filename = gtk_icon_info_get_filename (icon_info);
        if (filename != NULL) {
                basename = g_path_get_basename (filename);
@@ -581,30 +562,6 @@ nautilus_icon_info_get_pixbuf_at_size (NautilusIconInfo  *icon,
        return scaled_pixbuf;
 }
 
-gboolean
-nautilus_icon_info_get_embedded_rect (NautilusIconInfo  *icon,
-                                     GdkRectangle      *rectangle)
-{
-       *rectangle = icon->embedded_rect;
-       return icon->got_embedded_rect;
-}
-
-gboolean
-nautilus_icon_info_get_attach_points (NautilusIconInfo  *icon,
-                                     GdkPoint         **points,
-                                     gint              *n_points)
-{
-       *n_points = icon->n_attach_points;
-       *points = icon->attach_points;
-       return icon->n_attach_points != 0;
-}
-
-const char *
-nautilus_icon_info_get_display_name   (NautilusIconInfo  *icon)
-{
-       return icon->display_name;
-}
-
 const char *
 nautilus_icon_info_get_used_name (NautilusIconInfo  *icon)
 {
diff --git a/libnautilus-private/nautilus-icon-info.h b/libnautilus-private/nautilus-icon-info.h
index 1f87b2d..e8446ec 100644
--- a/libnautilus-private/nautilus-icon-info.h
+++ b/libnautilus-private/nautilus-icon-info.h
@@ -71,12 +71,6 @@ GdkPixbuf *           nautilus_icon_info_get_pixbuf_nodefault_at_size (NautilusI
                                                                       gsize              forced_size);
 GdkPixbuf *           nautilus_icon_info_get_pixbuf_at_size           (NautilusIconInfo  *icon,
                                                                       gsize              forced_size);
-gboolean              nautilus_icon_info_get_embedded_rect            (NautilusIconInfo  *icon,
-                                                                      GdkRectangle      *rectangle);
-gboolean              nautilus_icon_info_get_attach_points            (NautilusIconInfo  *icon,
-                                                                      GdkPoint         **points,
-                                                                      gint              *n_points);
-const char *          nautilus_icon_info_get_display_name             (NautilusIconInfo  *icon);
 const char *          nautilus_icon_info_get_used_name                (NautilusIconInfo  *icon);
 
 void                  nautilus_icon_info_clear_caches                 (void);
diff --git a/src/nautilus-canvas-view-container.c b/src/nautilus-canvas-view-container.c
index a966713..e820295 100644
--- a/src/nautilus-canvas-view-container.c
+++ b/src/nautilus-canvas-view-container.c
@@ -51,15 +51,11 @@ static NautilusIconInfo *
 nautilus_canvas_view_container_get_icon_images (NautilusCanvasContainer *container,
                                              NautilusCanvasIconData      *data,
                                              int                    size,
-                                             char                 **embedded_text,
                                              gboolean               for_drag_accept,
-                                             gboolean               need_large_embeddded_text,
-                                             gboolean              *embedded_text_needs_loading,
                                              gboolean              *has_window_open)
 {
        NautilusCanvasView *canvas_view;
        NautilusFile *file;
-       gboolean use_embedding;
        NautilusFileIconFlags flags;
        NautilusIconInfo *icon_info;
        GdkPixbuf *pixbuf;
@@ -73,21 +69,12 @@ nautilus_canvas_view_container_get_icon_images (NautilusCanvasContainer *contain
        g_assert (NAUTILUS_IS_FILE (file));
        canvas_view = get_canvas_view (container);
        g_return_val_if_fail (canvas_view != NULL, NULL);
-
-       use_embedding = FALSE;
-       if (embedded_text) {
-               *embedded_text = nautilus_file_peek_top_left_text (file, need_large_embeddded_text, 
embedded_text_needs_loading);
-               use_embedding = *embedded_text != NULL;
-       }
        
        *has_window_open = nautilus_file_has_open_window (file);
 
        flags = NAUTILUS_FILE_ICON_FLAGS_USE_MOUNT_ICON_AS_EMBLEM |
                NAUTILUS_FILE_ICON_FLAGS_USE_THUMBNAILS;
 
-       if (use_embedding) {
-               flags |= NAUTILUS_FILE_ICON_FLAGS_EMBEDDING_TEXT;
-       }
        if (for_drag_accept) {
                flags |= NAUTILUS_FILE_ICON_FLAGS_FOR_DRAG_ACCEPT;
        }
@@ -148,40 +135,6 @@ nautilus_canvas_view_container_get_icon_description (NautilusCanvasContainer *co
 }
 
 static void
-nautilus_canvas_view_container_start_monitor_top_left (NautilusCanvasContainer *container,
-                                                    NautilusCanvasIconData      *data,
-                                                    gconstpointer          client,
-                                                    gboolean               large_text)
-{
-       NautilusFile *file;
-       NautilusFileAttributes attributes;
-               
-       file = (NautilusFile *) data;
-
-       g_assert (NAUTILUS_IS_FILE (file));
-
-       attributes = NAUTILUS_FILE_ATTRIBUTE_TOP_LEFT_TEXT;
-       if (large_text) {
-               attributes |= NAUTILUS_FILE_ATTRIBUTE_LARGE_TOP_LEFT_TEXT;
-       }
-       nautilus_file_monitor_add (file, client, attributes);
-}
-
-static void
-nautilus_canvas_view_container_stop_monitor_top_left (NautilusCanvasContainer *container,
-                                                   NautilusCanvasIconData      *data,
-                                                   gconstpointer          client)
-{
-       NautilusFile *file;
-
-       file = (NautilusFile *) data;
-
-       g_assert (NAUTILUS_IS_FILE (file));
-
-       nautilus_file_monitor_remove (file, client);
-}
-
-static void
 nautilus_canvas_view_container_prioritize_thumbnailing (NautilusCanvasContainer *container,
                                                      NautilusCanvasIconData      *data)
 {
@@ -542,8 +495,6 @@ nautilus_canvas_view_container_class_init (NautilusCanvasViewContainerClass *kla
        ic_class->get_icon_text = nautilus_canvas_view_container_get_icon_text;
        ic_class->get_icon_images = nautilus_canvas_view_container_get_icon_images;
        ic_class->get_icon_description = nautilus_canvas_view_container_get_icon_description;
-       ic_class->start_monitor_top_left = nautilus_canvas_view_container_start_monitor_top_left;
-       ic_class->stop_monitor_top_left = nautilus_canvas_view_container_stop_monitor_top_left;
        ic_class->prioritize_thumbnailing = nautilus_canvas_view_container_prioritize_thumbnailing;
 
        ic_class->compare_icons = nautilus_canvas_view_container_compare_icons;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]