nautilus/ChangeLog-20000414

3678 lines
145 KiB
Plaintext
Raw Normal View History

Changed the icon factory interface in a few ways: 1) There's no longer a * libnautilus/nautilus-icon-factory.h: * libnautilus/nautilus-icon-factory.c: (nautilus_icon_factory_new): (nautilus_icon_factory_destroy): (nautilus_get_current_icon_factory): (nautilus_icon_factory_get_icon_for_file): (nautilus_icon_factory_set_theme): (nautilus_icon_factory_get_icon_by_name): (nautilus_icon_factory_get_pixbuf_for_icon): (nautilus_scalable_icon_ref): (nautilus_scalable_icon_unref): (nautilus_scalable_icon_get_name): (scalable_icon_get): (icon_set_possibly_free): (scalable_icon_new): Changed the icon factory interface in a few ways: 1) There's no longer a NautilusIconFactory object. There's just a single global icon factory. If we find that we need multiple factories, we can implement that later. 2) Instead of going straight from a file to a pixbuf, you get a scalable icon, and then get a pixbuf from that. This allows you to choose the icon and then get different-sized versions of it without going through the icon selection process over and over again. There's also a name for each icon which can be stored in the metafile so you can get the same icon again before you have full information on a file. * src/nautilus-bookmark.c: (nautilus_bookmark_get_pixmap_and_mask): * src/file-manager/fm-directory-view-list.c: (install_icon): * src/file-manager/fm-icons-controller.c: (fm_icons_controller_get_icon_image): Changed icon factory clients to use the new interface. Maybe after a while I'll add a convenience function that's as simple as the old interface was for the common case where you want to go straight to the pixbuf, but lets try it this way for a while. * libnautilus/nautilus-string.h: * libnautilus/nautilus-string.c: (nautilus_has_prefix): Added nautilus_has_prefix. This checks to see if a string has a particular prefix. It's both clearer to read and more efficient than Andy's typical trick of calling strstr. * libnautilus/nautilus-lib-self-check-functions.h: * libnautilus/nautilus-string.c: Added self-checks for nautilus-string.c. The tests uncovered a bug in nautilus_string_to_int that I fixed. * nautilus-glib-extensions.c: Just a stray new-line.
2000-02-01 05:34:46 +00:00
2000-02-01 Darin Adler <darin@eazel.com>
* libnautilus/nautilus-icon-factory.h:
* libnautilus/nautilus-icon-factory.c:
(nautilus_icon_factory_new):
(nautilus_icon_factory_destroy):
(nautilus_get_current_icon_factory):
(nautilus_icon_factory_get_icon_for_file):
(nautilus_icon_factory_set_theme):
(nautilus_icon_factory_get_icon_by_name):
(nautilus_icon_factory_get_pixbuf_for_icon):
(nautilus_scalable_icon_ref):
(nautilus_scalable_icon_unref):
(nautilus_scalable_icon_get_name):
(scalable_icon_get):
(icon_set_possibly_free):
(scalable_icon_new):
Changed the icon factory interface in a few ways: 1) There's no
longer a NautilusIconFactory object. There's just a single global
icon factory. If we find that we need multiple factories, we can
implement that later. 2) Instead of going straight from a file to
a pixbuf, you get a scalable icon, and then get a pixbuf from
that. This allows you to choose the icon and then get
different-sized versions of it without going through the icon
selection process over and over again. There's also a name for
each icon which can be stored in the metafile so you can get the
same icon again before you have full information on a file.
* src/nautilus-bookmark.c:
(nautilus_bookmark_get_pixmap_and_mask):
* src/file-manager/fm-directory-view-list.c:
(install_icon):
* src/file-manager/fm-icons-controller.c:
(fm_icons_controller_get_icon_image):
Changed icon factory clients to use the new interface. Maybe
after a while I'll add a convenience function that's as simple as
the old interface was for the common case where you want to go
straight to the pixbuf, but lets try it this way for a while.
* libnautilus/nautilus-string.h:
* libnautilus/nautilus-string.c:
(nautilus_has_prefix):
Added nautilus_has_prefix. This checks to see if a string has a
particular prefix. It's both clearer to read and more efficient
than Andy's typical trick of calling strstr.
* libnautilus/nautilus-lib-self-check-functions.h:
* libnautilus/nautilus-string.c:
Added self-checks for nautilus-string.c. The tests uncovered a
bug in nautilus_string_to_int that I fixed.
* nautilus-glib-extensions.c:
Just a stray new-line.
2000-02-01 John Sullivan <sullivan@eazel.com>
Fixed bug where selection info didn't appear in the status bar when
Select All was performed in the list view.
* libnautilus/gtkflist.c:
(select_or_unselect_row_cb): New function, emits SELECTION_CHANGED
signal.
(gtk_flist_initialize): Connect parent class's "select_row" and
"unselect_row" signals to select_or_unselect_row_cb.
(select_row): Remove emission of SELECTION_CHANGED signal here since
it's now handled at the correct bottleneck.
2000-02-01 Darin Adler <darin@eazel.com>
Started work on icon stretching. In the process, I am doing some
cleanup on the icon container, and I am checking in some of that
before the stretching is implemented.
* libnautilus/gnome-icon-container-private.h:
* libnautilus/gnome-icon-container.c:
(icon_is_in_region):
Got rid of width and height stored in each icon.
* libnautilus/gnome-icon-container.c:
A lot of cleanup, including getting rid of the
icon_get_text_bounding_box function.
* libnautilus/gnome-icon-container.c:
(gnome_icon_container_begin_stretch):
(gnome_icon_container_stretch):
(gnome_icon_container_end_stretch):
(button_release_event):
(motion_notify_event):
(handle_icon_button_press):
First cut at adding stretching hooks in button handlers.
* libnautilus/nautilus-icons-view-icon-item.c:
(nautilus_icons_view_draw_text_box):
Rewrote to fix bug with position of text when it's too long for
a single line.
* libnautilus/nautilus-glib-extensions.h:
2000-01-31 22:45:00 +00:00
Added a macro named NAUTILUS_N_ELEMENTS.
src/ntl-index-panel.c:
src/explorer-location-bar.c:
libnautilus/gtkflist.c:
2000-01-31 22:45:00 +00:00
Used the NAUTILUS_N_ELEMENTS macro.
2000-01-31 Andy Hertzfeld <andy@eazel.com>
made the keyboard selection rectangle work again. It's no longer a
separate canvas object, but rather a state reflected by the icon_item
like regular selection
* libnautilus/gnome-icon-container-private.h:
removed the kdb_navigation_item field
* libnautilus/gnome-icon-container.c:
removed code that manipulated the kbd_navigation_item, replaced
with setting and clearing the "alt_selection" item attribute
* libnautilus/nautilus-icons-view-icon-item.c:
if the alt_selected attribute is set, frame the item's text with
a gray-stippled rectangle
2000-01-31 John Sullivan <sullivan@eazel.com>
Now saves/restores zoom level in icon & list views, and
sort column & direction in list view.
* nautilus-metadata.h: New #defines for ICON_VIEW_ZOOM_LEVEL_METADATA_KEY,
LIST_VIEW_ZOOM_LEVEL_METADATA_KEY, LIST_VIEW_SORT_COLUMN_METADATA_KEY,
LIST_VIEW_SORT_REVERSED_METADATA_KEY.
* src/file-manager/fm-directory-view.c:
(fm_directory_view_load_uri): Now emits the BEGIN_LOADING signal. This
signal was already defined but its use had been removed.
* src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_icons_set_zoom_level): Stores new zoom level in
the metadata.
(fm_directory_view_icons_begin_loading): Sets zoom level to the one
read from the metadata.
* src/file-manager/fm-directory-view-list.c:
Created #defines for column names stored in metadata.
(get_metadata_value_from_column), (get_column_from_metadata_value):
Helper functions for converting between column number and string to
store in metadata.
(fm_directory_view_list_begin_loading): New function: sets zoom level,
sort column, and sort direction to the values read from the metadata.
(fm_directory_view_initialize_class): Wire up begin_loading function
pointer.
(fm_directory_view_initialize): Change initial value of sort column
to LIST_VIEW_COLUMN_NONE, so when it changes later the right updating
will occur.
(compare_rows): Added another g_return_val_if_fail condition.
(create_flist): Removed some of the sorting set-up; it is now done
in begin_loading instead.
(fm_directory_view_list_set_zoom_level): Stores new zoom level in
the metadata.
(fm_directory_view_list_sort_items): Stores new sort column and
direction in metadata.
2000-01-31 Andy Hertzfeld <andy@eazel.com>
implemented the "select all" command in the context menus
* src/file-manager/directory_view.c,h:
added a directory_view_select_all slot for subclasses to override,
enabled "select all" item and attached a signal to the item, whose
callback calls fm_directory_view_select_all
* src/file-manager/directory_view_icons.c:
implemented directory_view_icons_select_all by invoking the "select all"
operation of GnomeIconContainer.
* src/file-manager/directory_view_list.c:
implemented directory_view_list_select_all by invoking the "select all"
operation of the clist widget
2000-01-31 Elliot Lee <sopwith@redhat.com>
* src/ntl-window-msgs.c, src/ntl-window-private.h: Update debugging messages. Allow
synchronous state changes (needed to avoid race conditions), and
don't reset the idle handler if the idle handler is already running.
* src/file-manager/fm-directory-view.c: Include
<libnautilus/libnautilus.h> rather than just
<libnautilus/nautilus-alloc.h> - nitpick in passing.
* src/ntl-uri-map.c: OK, don't check for NULL here, in an attempt to flush out bugs elsewhere.
Changed it to not attempt to create a GC just to measure the text. This * nautilus-icons-view-icon-item.c: (nautilus_icons_view_draw_text_box): Changed it to not attempt to create a GC just to measure the text. This makes it work when the widget is not realized. * nautilus-icons-view-icon-item.h: nautilus-icons-view-icon-item.c: gnome-icon-container-dnd.c: (nautilus_icons_view_icon_item_center_offset): Changed the parameter type to NautilusIconsViewIconItem. * fm-directory-view.c: (stop_load): (fm_directory_view_load_uri): Fixed code so that if you stop loading more than once, or stop before you even start, it won't send extra progress requests to the Nautilus shell or call stop_monitoring extra times on the NautilusDirectory object. * nautilus-icons-view-icon-item.h: nautilus-icons-view-icon-item.c: gnome-icon-container-dnd.c: Quick cleanup of the new NautilusIconsViewIconItem class. * libnautilus/gdk-extensions.c: libnautilus/gnome-icon-container-dnd.c: libnautilus/gnome-icon-container.c: libnautilus/gtkflist.c: libnautilus/nautilus-background-canvas-group.c: libnautilus/nautilus-background.c: libnautilus/nautilus-debug.c: libnautilus/nautilus-default-file-icon.c: libnautilus/nautilus-directory.c: libnautilus/nautilus-icon-factory.c: libnautilus/nautilus-icons-controller.c: libnautilus/nautilus-icons-view-icon-item.c: libnautilus/nautilus-lib-self-check-functions.c: libnautilus/nautilus-self-checks.c: libnautilus/nautilus-string.c: src/explorer-location-bar.c: src/file-manager/dfos-corba.c: src/file-manager/dfos-xfer-progress-dialog.c: src/file-manager/dfos-xfer.c: src/file-manager/dfos.c: src/file-manager/fm-directory-view-icons.c: src/file-manager/fm-directory-view-list.c: src/file-manager/fm-directory-view.c: src/file-manager/fm-icons-controller.c: src/file-manager/fm-main.c: src/nautilus-self-check-functions.c: src/ntl-index-panel.c: Got rid of #ifdef HAVE_CONFIG_H. Elliot says that we must always include <config.h>, but there's no reason to include that ifdef since we don't plan on building without a <config.h> ever.
2000-01-31 01:30:16 +00:00
2000-01-31 Darin Adler <darin@eazel.com>
* nautilus-icons-view-icon-item.c:
(nautilus_icons_view_draw_text_box):
Changed it to not attempt to create a GC just to measure the text.
This makes it work when the widget is not realized.
* nautilus-icons-view-icon-item.h:
nautilus-icons-view-icon-item.c:
gnome-icon-container-dnd.c:
(nautilus_icons_view_icon_item_center_offset):
Changed the parameter type to NautilusIconsViewIconItem.
* fm-directory-view.c:
(stop_load):
(fm_directory_view_load_uri):
Fixed code so that if you stop loading more than once, or
stop before you even start, it won't send extra progress
requests to the Nautilus shell or call stop_monitoring
extra times on the NautilusDirectory object.
* nautilus-icons-view-icon-item.h:
nautilus-icons-view-icon-item.c:
gnome-icon-container-dnd.c:
Quick cleanup of the new NautilusIconsViewIconItem class.
* libnautilus/gdk-extensions.c:
libnautilus/gnome-icon-container-dnd.c:
libnautilus/gnome-icon-container.c:
libnautilus/gtkflist.c:
libnautilus/nautilus-background-canvas-group.c:
libnautilus/nautilus-background.c:
libnautilus/nautilus-debug.c:
libnautilus/nautilus-default-file-icon.c:
libnautilus/nautilus-directory.c:
libnautilus/nautilus-icon-factory.c:
libnautilus/nautilus-icons-controller.c:
libnautilus/nautilus-icons-view-icon-item.c:
libnautilus/nautilus-lib-self-check-functions.c:
libnautilus/nautilus-self-checks.c:
libnautilus/nautilus-string.c:
src/explorer-location-bar.c:
src/file-manager/dfos-corba.c:
src/file-manager/dfos-xfer-progress-dialog.c:
src/file-manager/dfos-xfer.c:
src/file-manager/dfos.c:
src/file-manager/fm-directory-view-icons.c:
src/file-manager/fm-directory-view-list.c:
src/file-manager/fm-directory-view.c:
src/file-manager/fm-icons-controller.c:
src/file-manager/fm-main.c:
src/nautilus-self-check-functions.c:
src/ntl-index-panel.c:
Got rid of #ifdef HAVE_CONFIG_H. Elliot says that we must always
include <config.h>, but there's no reason to include that ifdef
since we don't plan on building without a <config.h> ever.
2000-01-31 Andy Hertzfeld <andy@eazel.com>
* libnautilus/gnome-icon-container-dnd.c:
fixed bug where icons were horizontally mis-positioned after dragging;
fixed by taking the center offset into account
2000-01-31 John Sullivan <sullivan@eazel.com>
* libnautilus/nautilus-directory.h:
* libnautilus/nautilus-directory.c:
(nautilus_directory_get_boolean_metadata),
(nautilus_directory_set_boolean_metadata),
(nautilus_directory_get_integer_metadata),
(nautilus_directory_set_integer_metadata): New convenience functions
for getting/setting metadata that's naturally in boolean or integer form.
I'll be adding clients for these next.
NautilusDirectory is now in charge of loading directories. FMDirectoryView has been relieved of that responsibility. * nautilus-directory.h: nautilus-directory.c: (nautilus_directory_start_monitoring): (nautilus_directory_stop_monitoring): (nautilus_directory_is_ready_for_layout): (nautilus_directory_new_file): (nautilus_directory_are_all_files_seen): Added monitoring API that's used to read the contents of a directory. Made nautilus_directory_new_file private since we now use the monitoring API instead. * fm-directory-view.c: (fm_directory_view_initialize): (stop_load): (display_pending_entries): (display_pending_files): (display_pending_idle_cb): (display_timeout_cb): (display_pending_timeout_cb): (directory_load_cb): (schedule_idle_display_of_pending_files): (schedule_timeout_display_of_pending_files): (unschedule_idle_display_of_pending_files): (unschedule_timeout_display_of_pending_files): (unschedule_display_of_pending_files): (add_files_cb): (fm_directory_view_activate_entry): (fm_directory_view_load_uri): (disconnect_model_handlers): (fm_directory_view_stop): Changed to use monitoring instead of directly calling gnome_vfs_async_load_directory directly. * fm-directory-view.c: (update_zoom_menu_items): (zoom_in_cb): (zoom_out_cb): (pop_up_context_menu): (pop_up_temporary_context_menu): (append_background_items): (create_background_context_menu): (fm_directory_view_popup_item_context_menu): (fm_directory_view_popup_background_context_menu): Changed to re-created background menu each time instead of keeping a single global menu up to date. This is simpler, and the imperceptible additional delay from recreating the menu each time should not be a problem. * ntl-window.c: (nautilus_window_up): ntl-map.c: (nautilus_navinfo_new): Handle the case where the current URI is NULL. * fm-directory-view-icons.c: (create_icon_container): Removed the leftover puts calls in here. This gets rid of "A", "B", "C" on each start of nautilus.
2000-01-30 23:39:22 +00:00
2000-01-31 Darin Adler <darin@eazel.com>
NautilusDirectory is now in charge of loading directories.
FMDirectoryView has been relieved of that responsibility.
* nautilus-directory.h:
nautilus-directory.c:
(nautilus_directory_start_monitoring):
(nautilus_directory_stop_monitoring):
(nautilus_directory_is_ready_for_layout):
(nautilus_directory_new_file):
(nautilus_directory_are_all_files_seen):
Added monitoring API that's used to read the contents of
a directory. Made nautilus_directory_new_file private since
we now use the monitoring API instead.
* fm-directory-view.c:
(fm_directory_view_initialize):
(stop_load):
(display_pending_entries):
(display_pending_files):
(display_pending_idle_cb):
(display_timeout_cb):
(display_pending_timeout_cb):
(directory_load_cb):
(schedule_idle_display_of_pending_files):
(schedule_timeout_display_of_pending_files):
(unschedule_idle_display_of_pending_files):
(unschedule_timeout_display_of_pending_files):
(unschedule_display_of_pending_files):
(add_files_cb):
(fm_directory_view_activate_entry):
(fm_directory_view_load_uri):
(disconnect_model_handlers):
(fm_directory_view_stop):
Changed to use monitoring instead of directly calling
gnome_vfs_async_load_directory directly.
* fm-directory-view.c:
(update_zoom_menu_items):
(zoom_in_cb):
(zoom_out_cb):
(pop_up_context_menu):
(pop_up_temporary_context_menu):
(append_background_items):
(create_background_context_menu):
(fm_directory_view_popup_item_context_menu):
(fm_directory_view_popup_background_context_menu):
Changed to re-created background menu each time instead of
keeping a single global menu up to date. This is simpler, and
the imperceptible additional delay from recreating the menu
each time should not be a problem.
* ntl-window.c: (nautilus_window_up):
ntl-map.c: (nautilus_navinfo_new):
Handle the case where the current URI is NULL.
* fm-directory-view-icons.c: (create_icon_container):
Removed the leftover puts calls in here.
This gets rid of "A", "B", "C" on each start of nautilus.
2000-01-31 John Sullivan <sullivan@eazel.com>
Put all metadata keys in a central place so we can keep
track of them.
* libnautilus/nautilus-metadata.h: New file, contains
#defines for all the metadata keys currently in use.
* libnautilus/Makefile.am: add nautilus-metadata.h to list of headers.
* src/ntl-index-panel.c:
* src/file-manager/fm-directory-view-icons.c:
* src/file-manager/fm-directory-view-list.c:
Update all non-test callers of nautilus_directory_get_metadata and
nautilus_directory_set_metadata to use new #defines
2000-01-31 John Sullivan <sullivan@eazel.com>
Improved zooming API and made zoom items on item context
menu disable properly. (There's still a bug with disabling
the background menu if an item menu ever appears; Darin will
fix this in his next checkin.)
* src/file-manager/fm-directory-view.c:
* src/file-manager/fm-directory-view.h:
(can_zoom_in), (can_zoom_out): New function pointers for subclasses
to replace.
(fm_directory_view_can_zoom_in), (fm_directory_view_can_zoom_out):
New functions that call through to the new function pointers.
(bump_zoom_level), (fm_directory_view_bump_zoom_level):
Removed return value in favor of new functions.
(update_zoom_menu_items): Helper function to update sensitivity of
background context menu Zoom In and Zoom Out items. Darin will eliminate
this with his next checkin.
(zoom_in_cb), (zoom_out_cb): Now use update_zoom_menu_items to share code.
(append_background_items): Set sensitivity of Zoom In and Zoom Out items
at creation time.
* src/file-manager/fm-directory-view-list.c:
(fm_directory_view_list_bump_zoom_level): Removed return value.
(fm_directory_view_list_can_zoom_in), (fm_directory_view_list_can_zoom_out):
New functions, compare current zoom level against limits.
(fm_directory_view_list_get_zoom_level),
(fm_directory_view_list_set_zoom_level): New convenience functions,
deployed throughout this file.
(fm_directory_view_list_initialize_class): Replace can_zoom_in and
can_zoom_out function pointers.
* src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_icons_bump_zoom_level): Removed return value.
(fm_directory_view_icons_can_zoom_in), (fm_directory_view_icons_can_zoom_out):
New functions, compare current zoom level against limits.
(fm_directory_view_icons_get_zoom_level): New convenience function,
deployed throughout this file.
(fm_directory_view_icons_initialize_class): Replace can_zoom_in and
can_zoom_out function pointers.
2000-01-30 Andy Hertzfeld <andy@eazel.com>
made fonts scale according to the zoom level:
* libnautilus/gnome-icon-container-private.h:
replaced label font with array of fonts
* libnautilus/gnome-icon-container.c:
load a font for each zoom level
* libnautilus/nautilus_icons_view_icon_item:c
use a font selected by the zoom level
enabled/disabled zoom items as necessary in context menu:
* src/file-manager/fm-directory-view-icons.c:
made bump_zoom_level return a boolean indicating if it can zoom further
* src/file-manager/fm-directory-view-list.c:
made bump_zoom_level return a boolean indicating if it can zoom further
* src/file-manager/fm-directory-view-list.c:
enable/disable items in zoom level according to the passed-back booleans
2000-01-28 Andy Hertzfeld <andy@eazel.com>
* libnautilus/gnome-icon-container-dnd.c:
made shadow rectangles track icons properly by adding in the center offset
2000-01-28 John Sullivan <sullivan@eazel.com>
A little zoom cleanup:
* libnautilus/gnome-icon-container-private.h: #include
nautilus-icon-factory.h and remove copy of NautilusZoomLevel enum.
* libnautilus/gnome-icon-container.c:
(gnome_icon_container_set_zoom_level): Now uses ratios of standard
NAUTILUS_ICON_SIZEs to compute canvas pixels/unit instead of locally
storing ratios.
* libnautilus/nautilus-icon-factory.h:
Changed pixel sizes of some NAUTILUS_ICON_SIZE #defines to match
the ratios formerly used in gnome-icon-container.c
Added icons to bookmarks menu and window:
* libnautilus/nautilus-directory.c: (nautilus_file_get): Changed
options passed to gnome_vfs_get_file_info to match those used in
directory view; this causes the mime type to be read so the custom
image icon can appear.
* src/nautilus-bookmark.c:
* src/nautilus-bookmark.h:
Now uses details structure to hold implementation details.
(nautilus_bookmark_get_pixmap_and_mask): New utility function to
get image suitable for use in a GtkMenuItem or GtkCList
(nautilus_bookmark_destroy): Free details structure
(init): Alloc details structure
* src/nautilus-bookmarks-menu.c:
(create_pixmap_widget_for_bookmark): New utility function to create
the kind of pixmap widget that a menu item likes.
(bookmark_menu_item_new): New utility function that returns a menu
item with bookmark's icon & name installed.
(nautilus_bookmarks_menu_repopulate): Uses bookmark_menu_item_new.
* src/nautilus-bookmarks-window.c:
Now uses #defines for the list columns (icon & name)
(create_bookmarks_window): Create one more column to hold icon;
set column width & row height taking new icon column into account.
(install_bookmark_icon): New function, installs pixmap & mask for
bookmark into GtkCList cell.
(repopulate): Fill in icon column as well as name column.
Fixed storage leaks:
* src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_destroy): free details structure
* src/file-manager/fm-directory-view-list.c:
(fm_directory_view_list_destroy): free details structure
* src/file-manager/fm-directory-view.c:
(fm_directory_view_icons_destroy): free details structure; also,
don't bother setting details->icons_not_positioned to NULL since
details is about to be freed.
2000-01-28 Andy Hertzfeld <andy@eazel.com>
* libnautilus/nautilus_icons_view_icon_item.c,h:
made icons be centered in their box by adding a center_offset method
and using it where appropriate.
* libnautilus/gnome-icon-container-dnd.c:
used center_offset in drag offset calculation
2000-01-28 John Sullivan <sullivan@eazel.com>
Moved FMIconCache to libnautilus, renaming it
NautilusIconFactory at the same time. Renamed all public
and private functions accordingly.
* RENAMING: removed this finished item.
* src/file-manager/fm-default-file-icon.c: Removed file
* src/file-manager/fm-default-file-icon.h: Removed file
* src/file-manager/fm-icon-cache.c: Removed file
* src/file-manager/fm-icon-cache.h: Removed file
* src/file-manager/Makefile.am: Took out mentions of removed files.
* libnautilus/nautilus-default-file-icon.c: New file
* libnautilus/nautilus-default-file-icon.h: New file
* libnautilus/nautilus-icon-factory.c: New file
* libnautilus/nautilus-icon-factory.h: New file
* libnautilus/Makefile.am: Added new files to build.
* src/file-manager/fm-directory-view-icons.c: Took out
#include for fm-icon-cache, which was obsolete in this file.
* src/file-manager/fm-directory-view-list.c: Renamed #include
and affected function calls.
* src/file-manager/fm-icons-controller.c: Renamed #include
and affected function calls.
2000-01-27 21:18:01 +00:00
2000-01-28 John Sullivan <sullivan@eazel.com>
Made zooming work in directory list view. Also made
right-click menu on a directory view always include
the non-icon-specific items.
* src/file-manager/fm-icon-cache.h:
* src/file-manager/fm-icon-cache.c:
(nautilus_icon_size_for_zoom_level): New function, maps
between NautilusZoomLevel and nominal icon sizes.
* src/file-manager/fm-directory-view.c:
(append_background_items): New utility function, adds the
non-file-specific context menu items to a menu.
(create_background_context_menu): Moved most of guts to
new append_background_items, which this now calls.
(create_item_context_menu): Now adds a separator and then
calls append_background_items. This means right-clicking on
an icon will show the icon-specific commands followed by the
non-icon-specific ones. This makes the non-icon-specific ones
easier to discover and access, especially in list view where
anywhere you click in a long list gives the item's context menu.
* src/file-manager/fm-directory-view-list.c:
Now stores zoom level rather than icon size in details structure.
(fm_directory_view_list_bump_zoom_level),
(fm_directory_view_list_set_zoom_level): New functions for setting
the zoom level.
(fm_directory_view_list_initialize_class): Wire up bump_zoom_level to
slot in parent class structure.
(compare_rows), (add_to_flist): Changed mechanism that temporarily
stores pending row data to use object data rather than a static variable
so it will work with multiple list views at the same time.
(fm_directory_view_list_get_icon_size): New function, gets icon size
from zoom level stored in details structure.
(create_flist): Deploy fm_directory_view_list_get_icon_size where
details structure was examined before.
(install_icon): Removed NautilusFile and column parameters; made function
compute these internally.
2000-01-28 Elliot Lee <sopwith@redhat.com>
* components/html/ntl-web-browser.c: Remove use of gtk_html_parse() - deprecated
in latest GtkHTML.
2000-01-28 Andy Hertzfeld <andy@eazel.com>
*libnautilus/gnome-icon-container-dnd.c:
fixed dragging when zoomed by scaling the pixbuf and offsets if necessary
2000-01-27 Andy Hertzfeld <andy@eazel.com>
*libnautilus/nautilus-icons-view-icon-item.c:
some fixes to improve positioning when zoomed by multiplying by pixel_per_unit
when appropriate
2000-01-27 John Sullivan <sullivan@eazel.com>
Finished this round of sorting architecture improvements.
NautilusDirectory is now in charge of loading directories. FMDirectoryView has been relieved of that responsibility. * nautilus-directory.h: nautilus-directory.c: (nautilus_directory_start_monitoring): (nautilus_directory_stop_monitoring): (nautilus_directory_is_ready_for_layout): (nautilus_directory_new_file): (nautilus_directory_are_all_files_seen): Added monitoring API that's used to read the contents of a directory. Made nautilus_directory_new_file private since we now use the monitoring API instead. * fm-directory-view.c: (fm_directory_view_initialize): (stop_load): (display_pending_entries): (display_pending_files): (display_pending_idle_cb): (display_timeout_cb): (display_pending_timeout_cb): (directory_load_cb): (schedule_idle_display_of_pending_files): (schedule_timeout_display_of_pending_files): (unschedule_idle_display_of_pending_files): (unschedule_timeout_display_of_pending_files): (unschedule_display_of_pending_files): (add_files_cb): (fm_directory_view_activate_entry): (fm_directory_view_load_uri): (disconnect_model_handlers): (fm_directory_view_stop): Changed to use monitoring instead of directly calling gnome_vfs_async_load_directory directly. * fm-directory-view.c: (update_zoom_menu_items): (zoom_in_cb): (zoom_out_cb): (pop_up_context_menu): (pop_up_temporary_context_menu): (append_background_items): (create_background_context_menu): (fm_directory_view_popup_item_context_menu): (fm_directory_view_popup_background_context_menu): Changed to re-created background menu each time instead of keeping a single global menu up to date. This is simpler, and the imperceptible additional delay from recreating the menu each time should not be a problem. * ntl-window.c: (nautilus_window_up): ntl-map.c: (nautilus_navinfo_new): Handle the case where the current URI is NULL. * fm-directory-view-icons.c: (create_icon_container): Removed the leftover puts calls in here. This gets rid of "A", "B", "C" on each start of nautilus.
2000-01-30 23:39:22 +00:00
* libnautilus/nautilus-directory.c:
(nautilus_file_compare_for_sort_internal): Made sorting NautilusFiles
by name be case-insensitive.
* src/file-manager/fm-directory-view.h:
* src/file-manager/fm-directory-view.c:
Removed enum FMDirectoryViewSortType (replaced by recently-added
NautilusFileSortType)
(fm_directory_view_sort): Removed this function; subclasses now
must handle sorting internally.
(fm_directory_view_repopulate): Removed this function, formerly
called only by fm_directory_view_sort.
* src/file-manager/fm-directory-view-list.c:
(fm_directory_view_list_initialize): list_view->details->sort_column
now starts out at LIST_VIEW_COLUMN_NAME.
(compare_rows): New function to compare rows for sorting GtkCList-style.
(create_flist): Set up GtkCList sorting mechanism; formerly I had been
ignoring it (unaware) and handling sorting from scratch.
(add_to_flist): Don't assume that newly-added item will be at end; also
add hack to make pending row data accessible to compare function.
(sort_criterion_from_column): New function, broken out of
fm_directory_view_list_sort_items.
(fm_directory_view_list_sort_items): Broke out sort criterion choosing,
now uses GtkCList-style sorting instead of asking FMDirectoryView to sort.
(install_icon): Added a couple more g_return_if_fails.
2000-01-27 Darin Adler <darin@eazel.com>
* src/ntl-app.c: Added missing includes to get it to compile.
* components/help/converters/.cvsignore:
components/help/converters/gnome-info2html2/.cvsignore:
components/help/converters/gnome-man2html2/.cvsignore:
Added Makefile.
2000-01-27 Maciej Stachowiak <mjs@eazel.com>
* src/Makefile.am, src/nautilus.goad, src/ntl-app.c,
src/file-manager/Makefile.am: Made the file manager component
statically linked in again.
* src/file-manager/ntl-file-manager.goad: Removed.
2000-01-27 Elliot Lee <sopwith@redhat.com>
* configure.in: Add components/help/converters/* makefiles.
* libnautilus/nautilus-directory.c: Check for NULL directory
result before doing stuff with it.
* src/ntl-index-panel.c: Ditto.
* src/ntl-prefs.c: Add help browser nav tree to list of possibilities.
* src/ntl-window-msgs.c: Handle non-VFS-handleable URIs correctly WRT 'up' button.
2000-01-27 Andy Hertzfeld <andy@eazel.com>
* libnautilus/nautilus-icons-view-icon-item.c:
made the canvas item respect the scale factor by removing code in
compute_viewport_affine that was defeating it. There's still a
bunch more to do to make it right for non-unity scale factors, but
at least we can start that now.
2000-01-27 Andy Hertzfeld <andy@eazel.com>
hooked zooming up to the background context menu; right now the canvas item
doesn't work at different zoom levels properly, which we'll fix soon.
* libnautilus/fm-directory-view.c,h:
enable zoom in and zoom out items and hooked them up to callback
added a bump_zoom_level slot, to be overriden by subclasses, which the zoom callback use
* libnautilus/fm-directory-view-icons.c:
added method for bump_zoom_index that calls the icon container to do the work
* libnautilus/gnome-icon-container-private.h:
added a private instance variable for zoom level
* libnautilus/gnome-icon-container.c,.h:
added methods for get_zoom_level and set_zoom_level
2000-01-27 01:04:19 +00:00
2000-01-27 Darin Adler <darin@eazel.com>
* libnautilus/gnome-icon-container.c:
(icon_select):
Fixed a bug that was causing some icons to not get
selected or unselected properly due to strangeness of
bit fields.
* libnautilus/gnome-progressive-loader.h:
libnautilus/gnome-progressive-loader.c:
libnautilus/Makefile.am:
Got rid of GnomeProgressiveLoader.
We're not going to use it.
* RENAMING: Andy added a new file that matched RENAMING,
but then I changed my mind about a renaming, spawning yet
more renaming!
* src/file-manager/fm-directory-view-icons.c:
Just tiny reformatting.
2000-01-27 John Sullivan <sullivan@eazel.com>
More work towards changing the sorting framework, and
fixed some bugs in nautilus_file_get.
* libnautilus/nautilus-directory.h:
Added NautilusFileSortType enum.
(nautilus_file_compare_for_sort): New function
(nautilus_file_compare_for_sort_reversed): New function
* libnautilus/nautilus-directory.c:
(nautilus_file_ref): New function (prototype already existed).
(nautilus_file_get): file_info had been stack variable,
but that didn't work right, so now it's xxx_new()ed.
Also ref'ed file before returning.
(nautilus_file_compare_for_sort),
(nautilus_file_compare_for_sort_reversed),
(nautilus_file_compare_for_sort_internal): New functions.
(nautilus_self_check_directory): Added some simple tests for
nautilus_file_get and nautilus_file_compare_xxx.
* src/file-manager/fm-directory-view.c:
(fm_directory_view_load_uri): Removed sort_rules that were
passed in to gnome_vfs_asynch_load_directory_uri, since they
had no effect and we're changing the sorting framework.
2000-01-27 Elliot Lee <sopwith@redhat.com>
* libnautilus/Makefile.am: Link to $(BONOBO_LIBS)
* libnautilus/gnome-icon-container.c: Include <string.h> to get
prototype for memset.
2000-01-26 Maciej Stachowiak <mjs@eazel.com>
* components/help/hyperbola-main.c,
components/help/hyperbola-nav-tree.c,
components/history/ntl-history-view.c, components/html/main.c,
components/html/ntl-web-browser.c,
components/websearch/ntl-web-search.c, idl/nautilus.idl,
libnautilus/gnome-icon-container.c,
libnautilus/gnome-progressive-loader.c,
libnautilus/gnome-progressive-loader.h, libnautilus/libnautilus.h,
libnautilus/ntl-content-view-frame.c,
libnautilus/ntl-meta-view-frame.c, libnautilus/ntl-view-frame.c,
libnautilus/ntl-view-frame.h, src/nautilus.h,
src/ntl-index-panel.c, src/ntl-view-bonobo-control.c,
src/ntl-view-bonobo-subdoc.c, src/ntl-view-frame-svr.c,
src/ntl-view-nautilus.c, src/ntl-view-private.h, src/ntl-view.c,
src/ntl-view.h, src/ntl-window.c, src/ntl-window.h,
src/file-manager/dfos-corba.h, src/file-manager/dfos-xfer.c,
src/file-manager/dfos-xfer.h, src/file-manager/fm-main.c: Build
with the recent Bonobo global renaming, and Havoc's changes. A
patch from Kjartan Maraas <kmaraas@online.no> and scripts from Nat
Friedman <nat@helixcode.com> were a very helpful starting point.
2000-01-26 Havoc Pennington <hp@pobox.com>
* src/nautilus-gconf.h, src/nautilus-gconf.c: Trivial files I'd
written before getting stuck on the OAF thing, that might be of
interest. I have some other bits I did that aren't worth checking
in, Ramiro said he's doing the prefs dialog.
2000-01-26 John Sullivan <sullivan@eazel.com>
Moved list view sort indicator to left of right-justified
columns.
* src/file-manager/fm-directory-view-list.c:
(create_flist): Marked the sort indicators with special
data/value pairs so they can be located later regardless
of view order. Made right-justified ones use pack_start
instead of pack_end.
(get_sort_indicator): Find sort indicators from special
data/value pairs rather than relying on view order.
2000-01-26 John Sullivan <sullivan@eazel.com>
A few changes in the direction of improving the directory
view sorting architecture. No visible effects yet.
* src/file-manager/fm-directory-view-icons.c:
(create_icon_container): Took out useless call to
fm_directory_view_populate().
* src/file-manager/fm-directory-view-list.c:
(fm_directory_view_list_sort_items): New function, extracted
from column_clicked_cb, that does the actual sorting.
(column_clicked_cb): Replaced actual sorting code with
call to new fm_directory_view_list_sort_items; retained
setup code.
(create_flist): Took out useless call to
fm_directory_view_populate().
* src/file-manager/fm-directory-view.h:
(fm_directory_view_populate): Removed this call from public API.
* src/file-manager/fm-directory-view.c:
(fm_directory_view_populate): Made static and renamed to
..._repopulate now that I better understand its use. Soon it will
go away entirely.
2000-01-26 Andy Hertzfeld <andy@eazel.com>
* libnautilus/gnome-icon-container-dnd.c:
made the drag shadow have the same dimensions as the icon being dragged;
fixed bug where it was confusing the width and height order in the
custom uri it built for dragging within Nautilus
2000-01-26 Darin Adler <darin@eazel.com>
* libnautilus/nautilus-directory.c:
(nautilus_file_get_name):
Fixed an assert I missed.
2000-01-26 Darin Adler <darin@eazel.com>
* libnautilus/nautilus-directory.h:
libnautilus/nautilus-directory.c:
(nautilus_file_get):
(nautilus_file_detach):
(nautilus_directory_finalize):
(nautilus_file_unref):
Added interface to get a NautilusFile for a specific file rather than
a file from a directory that we are scanning.
* libnautilus/nautilus-glib-extensions.c:
(check_tm_to_g_date):
A little cleanup of the self-check code.
* libnautilus/Makefile.am:
libnautilus/libnautilus.h:
libnautilus/nautilus-alloc.h:
libnautilus/nautilus-directory.h:
Moved g_alloca into its own header file so you don't have to include
all the Bonobo stuff just to use g_alloca.
2000-01-26 Andy Hertzfeld <andy@eazel.com>
* src/file-manager/fm-icon-cache.c:
first cut at making images with small file sizes display as themselves
* libnautilus/nautilus-icons-view-icon-item.c:
clean-ups, plus added alternate selection boolean for keyboard selection
2000-01-25 John Sullivan <sullivan@eazel.com>
* libnautilus/nautilus-directory.c:
(nautilus_file_get_date_as_string): A few cleanups
based on feedback from Darin and Havoc.
2000-01-25 Andy Hertzfeld <andy@eazel.com>
* libnautilus/nautilus-icons-view-icon-item.c
disabled icon centering code that was causing glitchey updates
Redid drag code so that it will work if there are multiple windows * libnautilus/gnome-icon-container-dnd.c: (create_selection_shadow): (set_gnome_icon_list_selection): (get_gnome_icon_list_selection): (gnome_icon_container_receive_dropped_icons): Redid drag code so that it will work if there are multiple windows involved, although we still don't handle copies. Changed selection to include the width and height of the icon, and to hold the top left of the icon. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.c: (move_icon): (gnome_icon_container_move_icon): Made move_icon visible to the DnD code, and added a raise boolean so it could move and icon and bring it to the front. (gnome_icon_container_get_icon_by_uri): (gnome_icon_container_select_list_unselect_others): Added new functions for use by DnD code. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.c: (handle_icon_button_press): Got rid of unused drag_x_offset and drag_y_offset. * libnautilus/gnome-icon-container.c: (icon_select): (icon_toggle_selected): (select_icon): (select_one_unselect_others): (toggle_icon): (unselect_all_but_one): (unselect_all): (rubberband_select_in_cell): (kbd_move_to): (kbd_space): (linger_select_timeout_cb): (handle_icon_button_press): (gnome_icon_container_select_all): (gnome_icon_container_unselect_all): Cleaned up selection logic and made it simpler. * libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (gnome_icon_container_xlate_selected): Got rid of unused function. * libnautilus/nautilus-self-checks.h: libnautilus/nautilus-self-checks.c: (nautilus_self_checks_failed): (nautilus_exit_if_self_checks_failed): src/ntl-main.c: (main): Added blank lines before and after the first and last failed checks when at least one check fails. * src/ntl-view.c: (nautilus_view_destroy): Removed a straggler message. (I hope Elliot's not still using it.) * RENAMING: Some new name ideas.
2000-01-25 23:49:39 +00:00
2000-01-25 Darin Adler <darin@eazel.com>
* libnautilus/gnome-icon-container-dnd.c:
(create_selection_shadow):
(set_gnome_icon_list_selection):
(get_gnome_icon_list_selection):
(gnome_icon_container_receive_dropped_icons):
Redid drag code so that it will work if there are multiple
windows involved, although we still don't handle copies.
Changed selection to include the width and height of the icon,
and to hold the top left of the icon.
* libnautilus/gnome-icon-container-private.h:
libnautilus/gnome-icon-container.c:
(move_icon):
(gnome_icon_container_move_icon):
Made move_icon visible to the DnD code, and added a raise boolean
so it could move and icon and bring it to the front.
(gnome_icon_container_get_icon_by_uri):
(gnome_icon_container_select_list_unselect_others):
Added new functions for use by DnD code.
* libnautilus/gnome-icon-container-private.h:
libnautilus/gnome-icon-container.c:
(handle_icon_button_press):
Got rid of unused drag_x_offset and drag_y_offset.
* libnautilus/gnome-icon-container.c:
(icon_select):
(icon_toggle_selected):
(select_icon):
(select_one_unselect_others):
(toggle_icon):
(unselect_all_but_one):
(unselect_all):
(rubberband_select_in_cell):
(kbd_move_to):
(kbd_space):
(linger_select_timeout_cb):
(handle_icon_button_press):
(gnome_icon_container_select_all):
(gnome_icon_container_unselect_all):
Cleaned up selection logic and made it simpler.
* libnautilus/gnome-icon-container.h:
libnautilus/gnome-icon-container.c:
(gnome_icon_container_xlate_selected):
Got rid of unused function.
* libnautilus/nautilus-self-checks.h:
libnautilus/nautilus-self-checks.c:
(nautilus_self_checks_failed):
(nautilus_exit_if_self_checks_failed):
src/ntl-main.c:
(main):
Added blank lines before and after the first and last failed
checks when at least one check fails.
* src/ntl-view.c:
(nautilus_view_destroy):
Removed a straggler message. (I hope Elliot's not still using it.)
* RENAMING: Some new name ideas.
2000-01-25 John Sullivan <sullivan@eazel.com>
Better text for displayed file dates. This is currently used only
in the list view date column, but will be used later in icon view
when we get multiple lines of text per icon working.
* libnautilus/nautilus-glib-extensions.c:
* libnautilus/nautilus-glib-extensions.h:
New files, intended to hold nautilus code that logically belongs
in glib. Now contains a g_date constructor that takes a struct tm,
and a strdup_strftime function that returns a new string of exactly
the right size.
* libnautilus/Makefile.am: Build and install these two new files.
* libnautilus/nautilus-lib-self-check-functions.h: include the
new self-check function for nautilus-glib-extensions.
* libnautilus/nautilus-directory.c:
#include nautilus-glib-extensions.h
(nautilus_file_get_date_as_string): Replaced simple ctime version
with fancy version that uses shorter date format, the words
"today" and "yesterday" when appropriate, and the weekday name if
the date is in the last week (other than today or yesterday).
2000-01-25 Andy Hertzfeld <andy@eazel.com>
* libnautilus/nautilus-icons-view-icon-item.c,h:
new canvas item class for icon items. Now we use a single
canvas item to draw the icons instead of a group with two subitems.
This will pay-off when we implement the emblems, zooming and
special icons for text, etc. This is the first cut, I'm pretty
sure it doesn't work when pixels_per_item isn't 1.0 and there
are other small problems.
* libnautilus/gnome-icon-container-private.h:
removed old fields for sub-items
* libnautilus/Makefile.am:
added new item class to makefile
* libnautilus/gnome-icon-container-dnd.c:
drag asks main item for pixbuf instead of image item
* libnautilus/gnome-icon-container.c:
use new icon item instead of making group with two sub-items
2000-01-24 Maciej Stachowiak <mjs@eazel.com>
* src/file-manager/fm-directory-view.c,
src/file-manager/fm-directory-view.h
(fm_directory_view_popup_item_context_menu,
fm_directory_view_popup_background_context_menu): New functions
for subclasses to call, to implement right-click menus. Most of
the guts are here now. Machinery to merge view-specific items with
generic ones will be added here.
* src/file-manager/fm-directory-view-icons.c,
src/file-manager/fm-directory-view-list.c: Use the new interface
for right-click stuff.
* src/file-manager/fm-directory-view-icons.c: Corrected memory
management for background and item popup menus.
2000-01-24 Darin Adler <darin@eazel.com>
* gnome-icon-container-dnd.c:
(gnome_icon_container_receive_dropped_icons):
Removed bogus warning. Need to do some more work to get
dragging working with multiple windows, but there's no
easy way to detect that case, so just let it go.
* fm-directory-view-icons.c:
(icon_container_context_click_icon_cb):
(icon_container_context_click_background_cb):
Fixed the callbacks to match the new interface without the
icon name. I missed this in my check-in earlier today.
2000-01-24 John Sullivan <sullivan@eazel.com>
Added sort indicators to list view column titles
* src/file-manager/fm-directory-view-list.c:
Added #define LIST_VIEW_COLUMN_NONE
Added tiny in-line XPMs for up & down sort indicators.
(struct _FMDirectoryViewListDetails): Replaced
sort_type field with sort_column field.
(fm_directory_view_initalize): initialize details->sort_column
to LIST_VIEW_COLUMN_NONE
(get_sort_indicator), (hide_sort_indicator), (show_sort_indicator):
New functions for setting the sort indicators' states.
(column_clicked_cb): update details->sort_column and call
hide_sort_indicator and show_sort_indicator
(create_flist): Add sort indicator widgets to column titles,
initially hidden
(flist_activate_cb): Renamed "ignored" parameter and tested its
value, to make mjs happy.
2000-01-24 Maciej Stachowiak <mjs@eazel.com>
* libnautilus/gtkflist.c, libnautilus/gtkflist.h: Rename
"row_popup_menu" and "empty_popup_menu" signals to
"context_click_row" and "context_click_background" for more
consistency with the way the icon container does it. Removed
GdkEvent parameters from these signals. Added an int indicating
the row right-clicked.
(gtk_flist_button_press): Do not change the selection to the row
that gets right-clicked. It was inconsistent with the icon view
and most of the known universe.
2000-01-24 Darin Adler <darin@eazel.com>
Added a controller object that lets GnomeIconContainer ask questions and perform actions, even though only the FMDirectoryViewIcons knows how to answer the questions and perform the actions. Replaced use of nautilus_file_get_info with specific accessors for various file info. * libnautilus/Makefile.am: libnautilus/nautilus-icons-controller.h: libnautilus/nautilus-icons-controller.c: libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (icon_new_pixbuf): (gnome_icon_container_new): (gnome_icon_container_add): (gnome_icon_container_add_auto): Added NautilusIconsController, an interface provided so that the file manager can connect the icons up with the file code. This is all so we can keep the view/controller separation. This eliminates the need to pass around the icon name all the time, so the signals have changed to not take the icon name as a parameter. * src/file-manager/Makefile.am: src/file-manager/fm-icons-controller.c: src/file-manager/fm-icons-controller.h: Added FMIconsController, the actual controller used by the file manager instance of GnomeIconContainer. src/file-manager/fm-directory-view-icons.c: (create_icon_container): (add_icon_if_already_positioned): (add_icon_at_free_position): (icon_container_activate_cb): (fm_directory_view_icons_icon_moved_cb): Create and use the FMIconController. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container-dnd.c: (set_gnome_icon_list_selection): (set_uri_list_selection): libnautilus/gnome-icon-container.c: (gnome_icon_container_set_base_uri): src/file-manager/fm-directory-view-icons.c: (set_up_base_uri): (fm_directory_view_icons_begin_loading): Get rid of the old base_uri technique for handling drags. Instead the icon controller supplies URIs for icons when requested. * RENAMING: Proposed that we use NautilusIconsView as the new name for GnomeIconContainer instead of NautilusIconContainer. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (gnome_icon_container_initialize): (handle_icon_enter_notify): (handle_icon_leave_notify): Renamed browser mode to linger selection mode. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (icon_configure): (icon_position): (change_icon_mode): (gnome_icon_container_initialize): (gnome_icon_container_set_icon_mode): (gnome_icon_container_get_icon_mode): src/file-manager/fm-directory-view-icons.c: (fm_directory_view_icons_initialize): Got rid of icon mode, since we won't be using it. * libnautilus/gnome-icon-container-dnd.c: (get_gnome_icon_list_selection): Changed geometry parsing so it will not ignore extra characters after the numeric geometry. (gnome_icon_container_receive_dropped_icons): The code here tried to work when dragging icons between windows, but the implementation was actually only good within the same window, so I modified it to check for that case. * libnautilus/gnome-icon-container-dnd.c: (create_selection_shadow): (set_gnome_icon_list_selection): libnautilus/gnome-icon-container.c: (icon_position): Renamed GNOME_ICON_CONTAINER_ICON_XOFFSET to GNOME_ICON_CONTAINER_ICON_X_OFFSET and GNOME_ICON_CONTAINER_ICON_YOFFSET to GNOME_ICON_CONTAINER_ICON_Y_OFFSET. We use an underscore between words in identifiers. * libnautilus/gnome-icon-container.c: (destroy): Added code to remove timeouts and idles when the container is destroyed. * libnautilus/nautilus-directory.h: libnautilus/nautilus-directory.c: (nautilus_file_get_info): Get rid of the direct call to get GnomeVFSFileInfo. All info is accessed through individual functions. (nautilus_file_get_size): (nautilus_file_get_type): (nautilus_file_get_mime_type): (nautilus_file_is_executable): (nautilus_file_is_symbolic_link): Added new accessor functions as needed. src/file-manager/fm-directory-view.c: (display_selection_info): src/file-manager/fm-icon-cache.c: (fm_icon_cache_get_icon_set_for_file): (fm_icon_cache_get_icon_for_file): Change code to use the accessors instead of get_info. * libnautilus/nautilus-gtk-macros.h: (NAUTILUS_ASSIGN_MUST_OVERRIDE_SIGNAL): Changed macro to take a class pointer of the right type instead of taking both a casting macro name and a class pointer. src/file-manager/fm-directory-view.c: (fm_directory_view_initialize_class): Changed existing uses of macro to match. * src/file-manager/Makefile.am: src/file-manager/fm-icon-cache.c: src/file-manager/fm-default-file-icon.h: src/file-manager/fm-default-file-icon.c: Moved the default icon into its own file.
2000-01-24 18:27:20 +00:00
Added a controller object that lets GnomeIconContainer
ask questions and perform actions, even though only the
FMDirectoryViewIcons knows how to answer the questions
and perform the actions.
Replaced use of nautilus_file_get_info with specific
accessors for various file info.
* libnautilus/Makefile.am:
libnautilus/nautilus-icons-controller.h:
libnautilus/nautilus-icons-controller.c:
libnautilus/gnome-icon-container-private.h:
libnautilus/gnome-icon-container.h:
libnautilus/gnome-icon-container.c:
(icon_new_pixbuf):
(gnome_icon_container_new):
(gnome_icon_container_add):
(gnome_icon_container_add_auto):
Added NautilusIconsController, an interface provided so that the
file manager can connect the icons up with the file code. This is
all so we can keep the view/controller separation. This eliminates
the need to pass around the icon name all the time, so the signals
have changed to not take the icon name as a parameter.
* src/file-manager/Makefile.am:
src/file-manager/fm-icons-controller.c:
src/file-manager/fm-icons-controller.h:
Added FMIconsController, the actual controller used by the file
manager instance of GnomeIconContainer.
src/file-manager/fm-directory-view-icons.c:
(create_icon_container):
(add_icon_if_already_positioned):
(add_icon_at_free_position):
(icon_container_activate_cb):
(fm_directory_view_icons_icon_moved_cb):
Create and use the FMIconController.
* libnautilus/gnome-icon-container-private.h:
libnautilus/gnome-icon-container-dnd.c:
(set_gnome_icon_list_selection):
(set_uri_list_selection):
libnautilus/gnome-icon-container.c:
(gnome_icon_container_set_base_uri):
src/file-manager/fm-directory-view-icons.c:
(set_up_base_uri):
(fm_directory_view_icons_begin_loading):
Get rid of the old base_uri technique for handling drags. Instead
the icon controller supplies URIs for icons when requested.
* RENAMING: Proposed that we use NautilusIconsView as the new name
for GnomeIconContainer instead of NautilusIconContainer.
* libnautilus/gnome-icon-container-private.h:
libnautilus/gnome-icon-container.h:
libnautilus/gnome-icon-container.c:
(gnome_icon_container_initialize):
(handle_icon_enter_notify):
(handle_icon_leave_notify):
Renamed browser mode to linger selection mode.
* libnautilus/gnome-icon-container-private.h:
libnautilus/gnome-icon-container.h:
libnautilus/gnome-icon-container.c:
(icon_configure):
(icon_position):
(change_icon_mode):
(gnome_icon_container_initialize):
(gnome_icon_container_set_icon_mode):
(gnome_icon_container_get_icon_mode):
src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_icons_initialize):
Got rid of icon mode, since we won't be using it.
* libnautilus/gnome-icon-container-dnd.c:
(get_gnome_icon_list_selection):
Changed geometry parsing so it will not ignore extra characters
after the numeric geometry.
(gnome_icon_container_receive_dropped_icons):
The code here tried to work when dragging icons between windows,
but the implementation was actually only good within the same
window, so I modified it to check for that case.
* libnautilus/gnome-icon-container-dnd.c:
(create_selection_shadow):
(set_gnome_icon_list_selection):
libnautilus/gnome-icon-container.c:
(icon_position):
Renamed GNOME_ICON_CONTAINER_ICON_XOFFSET to
GNOME_ICON_CONTAINER_ICON_X_OFFSET and
GNOME_ICON_CONTAINER_ICON_YOFFSET to
GNOME_ICON_CONTAINER_ICON_Y_OFFSET. We use an underscore between
words in identifiers.
* libnautilus/gnome-icon-container.c:
(destroy):
Added code to remove timeouts and idles when the container is
destroyed.
* libnautilus/nautilus-directory.h:
libnautilus/nautilus-directory.c:
(nautilus_file_get_info):
Get rid of the direct call to get GnomeVFSFileInfo. All info is
accessed through individual functions.
(nautilus_file_get_size):
(nautilus_file_get_type):
(nautilus_file_get_mime_type):
(nautilus_file_is_executable):
(nautilus_file_is_symbolic_link):
Added new accessor functions as needed.
src/file-manager/fm-directory-view.c:
(display_selection_info):
src/file-manager/fm-icon-cache.c:
(fm_icon_cache_get_icon_set_for_file):
(fm_icon_cache_get_icon_for_file):
Change code to use the accessors instead of get_info.
* libnautilus/nautilus-gtk-macros.h:
(NAUTILUS_ASSIGN_MUST_OVERRIDE_SIGNAL):
Changed macro to take a class pointer of the right type instead
of taking both a casting macro name and a class pointer.
src/file-manager/fm-directory-view.c:
(fm_directory_view_initialize_class):
Changed existing uses of macro to match.
* src/file-manager/Makefile.am:
src/file-manager/fm-icon-cache.c:
src/file-manager/fm-default-file-icon.h:
src/file-manager/fm-default-file-icon.c:
Moved the default icon into its own file.
2000-01-24 John Sullivan <sullivan@eazel.com>
* libnautilus/gnome-icon-container.c:
(button_event_modifies_selection): New function, encapsulates idea
of which button events modify the selection. Formerly this was
done in several places and the answer was "those with the Control
Added a controller object that lets GnomeIconContainer ask questions and perform actions, even though only the FMDirectoryViewIcons knows how to answer the questions and perform the actions. Replaced use of nautilus_file_get_info with specific accessors for various file info. * libnautilus/Makefile.am: libnautilus/nautilus-icons-controller.h: libnautilus/nautilus-icons-controller.c: libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (icon_new_pixbuf): (gnome_icon_container_new): (gnome_icon_container_add): (gnome_icon_container_add_auto): Added NautilusIconsController, an interface provided so that the file manager can connect the icons up with the file code. This is all so we can keep the view/controller separation. This eliminates the need to pass around the icon name all the time, so the signals have changed to not take the icon name as a parameter. * src/file-manager/Makefile.am: src/file-manager/fm-icons-controller.c: src/file-manager/fm-icons-controller.h: Added FMIconsController, the actual controller used by the file manager instance of GnomeIconContainer. src/file-manager/fm-directory-view-icons.c: (create_icon_container): (add_icon_if_already_positioned): (add_icon_at_free_position): (icon_container_activate_cb): (fm_directory_view_icons_icon_moved_cb): Create and use the FMIconController. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container-dnd.c: (set_gnome_icon_list_selection): (set_uri_list_selection): libnautilus/gnome-icon-container.c: (gnome_icon_container_set_base_uri): src/file-manager/fm-directory-view-icons.c: (set_up_base_uri): (fm_directory_view_icons_begin_loading): Get rid of the old base_uri technique for handling drags. Instead the icon controller supplies URIs for icons when requested. * RENAMING: Proposed that we use NautilusIconsView as the new name for GnomeIconContainer instead of NautilusIconContainer. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (gnome_icon_container_initialize): (handle_icon_enter_notify): (handle_icon_leave_notify): Renamed browser mode to linger selection mode. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (icon_configure): (icon_position): (change_icon_mode): (gnome_icon_container_initialize): (gnome_icon_container_set_icon_mode): (gnome_icon_container_get_icon_mode): src/file-manager/fm-directory-view-icons.c: (fm_directory_view_icons_initialize): Got rid of icon mode, since we won't be using it. * libnautilus/gnome-icon-container-dnd.c: (get_gnome_icon_list_selection): Changed geometry parsing so it will not ignore extra characters after the numeric geometry. (gnome_icon_container_receive_dropped_icons): The code here tried to work when dragging icons between windows, but the implementation was actually only good within the same window, so I modified it to check for that case. * libnautilus/gnome-icon-container-dnd.c: (create_selection_shadow): (set_gnome_icon_list_selection): libnautilus/gnome-icon-container.c: (icon_position): Renamed GNOME_ICON_CONTAINER_ICON_XOFFSET to GNOME_ICON_CONTAINER_ICON_X_OFFSET and GNOME_ICON_CONTAINER_ICON_YOFFSET to GNOME_ICON_CONTAINER_ICON_Y_OFFSET. We use an underscore between words in identifiers. * libnautilus/gnome-icon-container.c: (destroy): Added code to remove timeouts and idles when the container is destroyed. * libnautilus/nautilus-directory.h: libnautilus/nautilus-directory.c: (nautilus_file_get_info): Get rid of the direct call to get GnomeVFSFileInfo. All info is accessed through individual functions. (nautilus_file_get_size): (nautilus_file_get_type): (nautilus_file_get_mime_type): (nautilus_file_is_executable): (nautilus_file_is_symbolic_link): Added new accessor functions as needed. src/file-manager/fm-directory-view.c: (display_selection_info): src/file-manager/fm-icon-cache.c: (fm_icon_cache_get_icon_set_for_file): (fm_icon_cache_get_icon_for_file): Change code to use the accessors instead of get_info. * libnautilus/nautilus-gtk-macros.h: (NAUTILUS_ASSIGN_MUST_OVERRIDE_SIGNAL): Changed macro to take a class pointer of the right type instead of taking both a casting macro name and a class pointer. src/file-manager/fm-directory-view.c: (fm_directory_view_initialize_class): Changed existing uses of macro to match. * src/file-manager/Makefile.am: src/file-manager/fm-icon-cache.c: src/file-manager/fm-default-file-icon.h: src/file-manager/fm-default-file-icon.c: Moved the default icon into its own file.
2000-01-24 18:27:20 +00:00
key down". Now the answer is "those with the Control or Shift key
down" to match list view (and traditional, i.e. Mac) behavior more
closely.
(button_press_event), (button_release_event),
(handle_icon_button_press): Deployed
button_event_modifies_selection.
(button_release_event): Check whether modifying selection and
don't activate on single-click if so.
(kbd_move_to): Just added comment.
2000-01-22 Havoc Pennington <hp@pobox.com>
* configure.in: check for libwww
* components/html/Makefile.am: add libwww flags
2000-01-21 Maciej Stachowiak <mjs@eazel.com>
* src/file-manager/fm-directory-view-icons.c: Added background and
item context click menus. Right now they only work for the
directory view, and contain only insensitive items. This needs
more work but I wanted to check in something basic.
2000-01-21 Havoc Pennington <hp@redhat.com>
* src/file-manager/Makefile.am (INCLUDES): fix to gnomecanvaspixbuf
* src/Makefile.am (INCLUDES): fix to gnomecanvaspixbuf
* libnautilus/Makefile.am (INCLUDES): fix to use gnomecanvaspixbuf
flags
* configure.in: Look for gnomecanvaspixbuf properly (via
gnome-config)
2000-01-21 23:29:15 +00:00
2000-01-21 John Sullivan <sullivan@eazel.com>
* src/ntl-window.c: Move Preferences item to Edit menu, its
traditional home.
2000-01-21 22:35:41 +00:00
2000-01-21 John Sullivan <sullivan@eazel.com>
Make icons appear in list view, and do some of the restructuring
necessary for supporting multiple icon sizes.
* src/file-manager/fm-icon-cache.h:
Added enum for Nautilus's 7 levels of zooming.
Added #defines for nominal icon sizes matching these 7 levels.
(fm_icon_cache_get_icon): Renamed to fm_icon_cache_get_icon_for_file,
and changed parameters to take a NautilusFile and a size (in pixels)
instead of a GnomeVFSFileInfo.
* src/file-manager/fm-icon-cache.c
Changed static vars fm_default_file_icon_width & height to use new
NAUTILUS_ICON_SIZE_STANDARD #define
(fm_icon_cache_get_icon_for_file): Renamed to
fm_icon_cache_get_icon_set_for_file to avoid collision with changed
public API call. Also changed parameters to take a NautilusFile instead
of a GnomeVFSFileInfo.
(fm_icon_cache_get_icon): Renamed to fm_icon_cache_get_icon_for_file,
and changed parameters to take a NautilusFile and a size (in pixels)
instead of a GnomeVFSFileInfo. If the size parameter is not the
standard size, calls fm_icon_cache_scale to get a scaled icon.
Eventually icons will be stored at various sizes, but for now we
always scale.
(fm_icon_cache_scale): New function, scales standard-sized GdkPixbuf
to given size.
* src/file-manager/fm-directory-view-icons.c:
(add_icon_if_already_positioned), (add_icon_at_free_position):
Updated callers of fm_icon_cache_get_icon, passing in
NAUTILUS_ICON_SIZE_STANDARD.
* src/file-manager/fm-directory-view-list.c:
(struct _FMDirectoryViewListDetails): Add icon_size field.
(fm_directory_view_list_initialize): Initialize icon_size field.
Added a controller object that lets GnomeIconContainer ask questions and perform actions, even though only the FMDirectoryViewIcons knows how to answer the questions and perform the actions. Replaced use of nautilus_file_get_info with specific accessors for various file info. * libnautilus/Makefile.am: libnautilus/nautilus-icons-controller.h: libnautilus/nautilus-icons-controller.c: libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (icon_new_pixbuf): (gnome_icon_container_new): (gnome_icon_container_add): (gnome_icon_container_add_auto): Added NautilusIconsController, an interface provided so that the file manager can connect the icons up with the file code. This is all so we can keep the view/controller separation. This eliminates the need to pass around the icon name all the time, so the signals have changed to not take the icon name as a parameter. * src/file-manager/Makefile.am: src/file-manager/fm-icons-controller.c: src/file-manager/fm-icons-controller.h: Added FMIconsController, the actual controller used by the file manager instance of GnomeIconContainer. src/file-manager/fm-directory-view-icons.c: (create_icon_container): (add_icon_if_already_positioned): (add_icon_at_free_position): (icon_container_activate_cb): (fm_directory_view_icons_icon_moved_cb): Create and use the FMIconController. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container-dnd.c: (set_gnome_icon_list_selection): (set_uri_list_selection): libnautilus/gnome-icon-container.c: (gnome_icon_container_set_base_uri): src/file-manager/fm-directory-view-icons.c: (set_up_base_uri): (fm_directory_view_icons_begin_loading): Get rid of the old base_uri technique for handling drags. Instead the icon controller supplies URIs for icons when requested. * RENAMING: Proposed that we use NautilusIconsView as the new name for GnomeIconContainer instead of NautilusIconContainer. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (gnome_icon_container_initialize): (handle_icon_enter_notify): (handle_icon_leave_notify): Renamed browser mode to linger selection mode. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (icon_configure): (icon_position): (change_icon_mode): (gnome_icon_container_initialize): (gnome_icon_container_set_icon_mode): (gnome_icon_container_get_icon_mode): src/file-manager/fm-directory-view-icons.c: (fm_directory_view_icons_initialize): Got rid of icon mode, since we won't be using it. * libnautilus/gnome-icon-container-dnd.c: (get_gnome_icon_list_selection): Changed geometry parsing so it will not ignore extra characters after the numeric geometry. (gnome_icon_container_receive_dropped_icons): The code here tried to work when dragging icons between windows, but the implementation was actually only good within the same window, so I modified it to check for that case. * libnautilus/gnome-icon-container-dnd.c: (create_selection_shadow): (set_gnome_icon_list_selection): libnautilus/gnome-icon-container.c: (icon_position): Renamed GNOME_ICON_CONTAINER_ICON_XOFFSET to GNOME_ICON_CONTAINER_ICON_X_OFFSET and GNOME_ICON_CONTAINER_ICON_YOFFSET to GNOME_ICON_CONTAINER_ICON_Y_OFFSET. We use an underscore between words in identifiers. * libnautilus/gnome-icon-container.c: (destroy): Added code to remove timeouts and idles when the container is destroyed. * libnautilus/nautilus-directory.h: libnautilus/nautilus-directory.c: (nautilus_file_get_info): Get rid of the direct call to get GnomeVFSFileInfo. All info is accessed through individual functions. (nautilus_file_get_size): (nautilus_file_get_type): (nautilus_file_get_mime_type): (nautilus_file_is_executable): (nautilus_file_is_symbolic_link): Added new accessor functions as needed. src/file-manager/fm-directory-view.c: (display_selection_info): src/file-manager/fm-icon-cache.c: (fm_icon_cache_get_icon_set_for_file): (fm_icon_cache_get_icon_for_file): Change code to use the accessors instead of get_info. * libnautilus/nautilus-gtk-macros.h: (NAUTILUS_ASSIGN_MUST_OVERRIDE_SIGNAL): Changed macro to take a class pointer of the right type instead of taking both a casting macro name and a class pointer. src/file-manager/fm-directory-view.c: (fm_directory_view_initialize_class): Changed existing uses of macro to match. * src/file-manager/Makefile.am: src/file-manager/fm-icon-cache.c: src/file-manager/fm-default-file-icon.h: src/file-manager/fm-default-file-icon.c: Moved the default icon into its own file.
2000-01-24 18:27:20 +00:00
(create_flist): Determine icon column width and row height from icon size.
(add_to_flist): Change parameters to take FMDirectoryViewList
instead of GtkFList, and remove FMIconCache parameter. Now calls
install_icon.
2000-01-21 22:35:41 +00:00
(fm_directory_view_list_add_entry): Update add_to_flist parameters.
(install_icon): New function, gets an appropriately-sized icon for
a NautilusFile and puts it into icon column in list.
2000-01-21 Elliot Lee <sopwith@redhat.com>
* src/ntl-window.[ch], src/ntl-window-msgs.c,
Added a controller object that lets GnomeIconContainer ask questions and perform actions, even though only the FMDirectoryViewIcons knows how to answer the questions and perform the actions. Replaced use of nautilus_file_get_info with specific accessors for various file info. * libnautilus/Makefile.am: libnautilus/nautilus-icons-controller.h: libnautilus/nautilus-icons-controller.c: libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (icon_new_pixbuf): (gnome_icon_container_new): (gnome_icon_container_add): (gnome_icon_container_add_auto): Added NautilusIconsController, an interface provided so that the file manager can connect the icons up with the file code. This is all so we can keep the view/controller separation. This eliminates the need to pass around the icon name all the time, so the signals have changed to not take the icon name as a parameter. * src/file-manager/Makefile.am: src/file-manager/fm-icons-controller.c: src/file-manager/fm-icons-controller.h: Added FMIconsController, the actual controller used by the file manager instance of GnomeIconContainer. src/file-manager/fm-directory-view-icons.c: (create_icon_container): (add_icon_if_already_positioned): (add_icon_at_free_position): (icon_container_activate_cb): (fm_directory_view_icons_icon_moved_cb): Create and use the FMIconController. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container-dnd.c: (set_gnome_icon_list_selection): (set_uri_list_selection): libnautilus/gnome-icon-container.c: (gnome_icon_container_set_base_uri): src/file-manager/fm-directory-view-icons.c: (set_up_base_uri): (fm_directory_view_icons_begin_loading): Get rid of the old base_uri technique for handling drags. Instead the icon controller supplies URIs for icons when requested. * RENAMING: Proposed that we use NautilusIconsView as the new name for GnomeIconContainer instead of NautilusIconContainer. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (gnome_icon_container_initialize): (handle_icon_enter_notify): (handle_icon_leave_notify): Renamed browser mode to linger selection mode. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (icon_configure): (icon_position): (change_icon_mode): (gnome_icon_container_initialize): (gnome_icon_container_set_icon_mode): (gnome_icon_container_get_icon_mode): src/file-manager/fm-directory-view-icons.c: (fm_directory_view_icons_initialize): Got rid of icon mode, since we won't be using it. * libnautilus/gnome-icon-container-dnd.c: (get_gnome_icon_list_selection): Changed geometry parsing so it will not ignore extra characters after the numeric geometry. (gnome_icon_container_receive_dropped_icons): The code here tried to work when dragging icons between windows, but the implementation was actually only good within the same window, so I modified it to check for that case. * libnautilus/gnome-icon-container-dnd.c: (create_selection_shadow): (set_gnome_icon_list_selection): libnautilus/gnome-icon-container.c: (icon_position): Renamed GNOME_ICON_CONTAINER_ICON_XOFFSET to GNOME_ICON_CONTAINER_ICON_X_OFFSET and GNOME_ICON_CONTAINER_ICON_YOFFSET to GNOME_ICON_CONTAINER_ICON_Y_OFFSET. We use an underscore between words in identifiers. * libnautilus/gnome-icon-container.c: (destroy): Added code to remove timeouts and idles when the container is destroyed. * libnautilus/nautilus-directory.h: libnautilus/nautilus-directory.c: (nautilus_file_get_info): Get rid of the direct call to get GnomeVFSFileInfo. All info is accessed through individual functions. (nautilus_file_get_size): (nautilus_file_get_type): (nautilus_file_get_mime_type): (nautilus_file_is_executable): (nautilus_file_is_symbolic_link): Added new accessor functions as needed. src/file-manager/fm-directory-view.c: (display_selection_info): src/file-manager/fm-icon-cache.c: (fm_icon_cache_get_icon_set_for_file): (fm_icon_cache_get_icon_for_file): Change code to use the accessors instead of get_info. * libnautilus/nautilus-gtk-macros.h: (NAUTILUS_ASSIGN_MUST_OVERRIDE_SIGNAL): Changed macro to take a class pointer of the right type instead of taking both a casting macro name and a class pointer. src/file-manager/fm-directory-view.c: (fm_directory_view_initialize_class): Changed existing uses of macro to match. * src/file-manager/Makefile.am: src/file-manager/fm-icon-cache.c: src/file-manager/fm-default-file-icon.h: src/file-manager/fm-default-file-icon.c: Moved the default icon into its own file.
2000-01-24 18:27:20 +00:00
src/ntl-window-private.h: Add a specific flag to indicate reload,
and make use of it.
* libnautilus/nautilus-directory.c: Allocate an extra byte in the
buffer, for safety's sake.
* src/ntl-window-msgs.c: Fix back/fwd buttons.
Added a controller object that lets GnomeIconContainer ask questions and perform actions, even though only the FMDirectoryViewIcons knows how to answer the questions and perform the actions. Replaced use of nautilus_file_get_info with specific accessors for various file info. * libnautilus/Makefile.am: libnautilus/nautilus-icons-controller.h: libnautilus/nautilus-icons-controller.c: libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (icon_new_pixbuf): (gnome_icon_container_new): (gnome_icon_container_add): (gnome_icon_container_add_auto): Added NautilusIconsController, an interface provided so that the file manager can connect the icons up with the file code. This is all so we can keep the view/controller separation. This eliminates the need to pass around the icon name all the time, so the signals have changed to not take the icon name as a parameter. * src/file-manager/Makefile.am: src/file-manager/fm-icons-controller.c: src/file-manager/fm-icons-controller.h: Added FMIconsController, the actual controller used by the file manager instance of GnomeIconContainer. src/file-manager/fm-directory-view-icons.c: (create_icon_container): (add_icon_if_already_positioned): (add_icon_at_free_position): (icon_container_activate_cb): (fm_directory_view_icons_icon_moved_cb): Create and use the FMIconController. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container-dnd.c: (set_gnome_icon_list_selection): (set_uri_list_selection): libnautilus/gnome-icon-container.c: (gnome_icon_container_set_base_uri): src/file-manager/fm-directory-view-icons.c: (set_up_base_uri): (fm_directory_view_icons_begin_loading): Get rid of the old base_uri technique for handling drags. Instead the icon controller supplies URIs for icons when requested. * RENAMING: Proposed that we use NautilusIconsView as the new name for GnomeIconContainer instead of NautilusIconContainer. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (gnome_icon_container_initialize): (handle_icon_enter_notify): (handle_icon_leave_notify): Renamed browser mode to linger selection mode. * libnautilus/gnome-icon-container-private.h: libnautilus/gnome-icon-container.h: libnautilus/gnome-icon-container.c: (icon_configure): (icon_position): (change_icon_mode): (gnome_icon_container_initialize): (gnome_icon_container_set_icon_mode): (gnome_icon_container_get_icon_mode): src/file-manager/fm-directory-view-icons.c: (fm_directory_view_icons_initialize): Got rid of icon mode, since we won't be using it. * libnautilus/gnome-icon-container-dnd.c: (get_gnome_icon_list_selection): Changed geometry parsing so it will not ignore extra characters after the numeric geometry. (gnome_icon_container_receive_dropped_icons): The code here tried to work when dragging icons between windows, but the implementation was actually only good within the same window, so I modified it to check for that case. * libnautilus/gnome-icon-container-dnd.c: (create_selection_shadow): (set_gnome_icon_list_selection): libnautilus/gnome-icon-container.c: (icon_position): Renamed GNOME_ICON_CONTAINER_ICON_XOFFSET to GNOME_ICON_CONTAINER_ICON_X_OFFSET and GNOME_ICON_CONTAINER_ICON_YOFFSET to GNOME_ICON_CONTAINER_ICON_Y_OFFSET. We use an underscore between words in identifiers. * libnautilus/gnome-icon-container.c: (destroy): Added code to remove timeouts and idles when the container is destroyed. * libnautilus/nautilus-directory.h: libnautilus/nautilus-directory.c: (nautilus_file_get_info): Get rid of the direct call to get GnomeVFSFileInfo. All info is accessed through individual functions. (nautilus_file_get_size): (nautilus_file_get_type): (nautilus_file_get_mime_type): (nautilus_file_is_executable): (nautilus_file_is_symbolic_link): Added new accessor functions as needed. src/file-manager/fm-directory-view.c: (display_selection_info): src/file-manager/fm-icon-cache.c: (fm_icon_cache_get_icon_set_for_file): (fm_icon_cache_get_icon_for_file): Change code to use the accessors instead of get_info. * libnautilus/nautilus-gtk-macros.h: (NAUTILUS_ASSIGN_MUST_OVERRIDE_SIGNAL): Changed macro to take a class pointer of the right type instead of taking both a casting macro name and a class pointer. src/file-manager/fm-directory-view.c: (fm_directory_view_initialize_class): Changed existing uses of macro to match. * src/file-manager/Makefile.am: src/file-manager/fm-icon-cache.c: src/file-manager/fm-default-file-icon.h: src/file-manager/fm-default-file-icon.c: Moved the default icon into its own file.
2000-01-24 18:27:20 +00:00
* src/ntl-window-msgs.c: Remove debugging printouts, and display
error dialogs.
* src/ntl-window-msgs.c, src/ntl-window.h: Fix the bug that was
causing list view to be blank.
2000-01-21 Darin Adler <darin@eazel.com>
Started some cleanup of the icon view.
* libnautilus/Makefile.am:
libnautilus/gnome-icon-container-layout.c:
libnautilus/gnome-icon-container-layout.h:
libnautilus/gnome-icon-container.c:
libnautilus/gnome-icon-container.h:
src/file-manager/fm-directory-view-icons.c:
src/file-manager/fm-directory-view-icons.h:
Got rid of the GnomeIconContainerLayout.
This was the old mechanism for saving and loading
icon positions and we have a better signal-based one.
Also made the new mechanism work more the way that
Ettore had intended to make the layout work, where
all the icons that have preassigned positions get
positioned first, then the ones that are auto positioned.
In the long run, we'll need something a bit fancier.
* libnautilus/gnome-icon-container-dnd.c:
libnautilus/gnome-icon-container.c:
libnautilus/gnome-icon-container.h:
libnautilus/gnome-icon-container-private.h:
Change the priv pointer to be named details to match
what we use in other places in Nautilus.
2000-01-21 16:23:06 +00:00
2000-01-21 John Sullivan <sullivan@eazel.com>
Made list view activation work on single click, like icon view.
* libnautilus/gtkflist.c
(struct _GtkFListDetails): Added single_click_mode
and button_down_time, renamed dnd_select_pending_row to
button_down_row.
Added #define MAX_CLICK_TIME, copied from gnome_icon_container.
(gtk_flist_initialize): Initialize single_click_mode to TRUE
(activate_row): New function, extracts code needed to activate
an item from its row number.
(gtk_flist_button_press): Save button_down_time, save
button_down_row more often, use activate_row () for double-click.
(gtk_flist_button_release): Activate on single click if single_click_mode
is true, selection isn't being extended, mouse hasn't moved to a different
row, and not too much time has passed.
(gtk_flist_motion): Deploy button_down_row name change.
2000-01-20 Andy Hertzfeld <andy@eazel.com>
* libnautilus/gnome-icon-container.c:
Disabled the pernicious call to relayout in size_allocate. We
will want to do automatic layout when the window size changes, but
this is the wrong level for it, it happens too frequently
2000-01-21 01:58:13 +00:00
2000-01-20 Elliot Lee <sopwith@redhat.com>
* src/ntl-window-msgs.c:
Missed piece in last commit.
2000-01-21 16:23:06 +00:00
John added this entry for Elliot, who made this change three
hours later than his last checkin. The comment is from the
cvs commit.
2000-01-21 01:58:13 +00:00
2000-01-20 Darin Adler <darin@eazel.com>
* src/file-manager/fm-directory-view.c:
(fm_directory_view_activate_entry):
Fixed double free that was causing lots of nasty errors in
the file manager.
(fm_directory_view_load_uri):
Made the old directory hang around a bit longer when loading
a new uri.
(display_selection_info):
(fm_directory_view_send_selection_change):
(display_selection_info_idle_cb):
Fixed a storage leak and broke out the selection change into
its own function instead of mixing it with the status line.
Also made the selection actually use URIs instead of just
names for the selected items.
* libnautilus/nautilus-directory.h:
libnautilus/nautilus-directory.c:
(nautilus_file_get_uri):
Added this function that gets a URI (rather than just a
leaf name).
* libnautilus/nautilus-directory.c:
(nautilus_directory_finalize):
(nautilus_self_check_directory):
Added more self checks and fixed a bug where a metadata
change would get lost if you delete the directory too soon
after making the change.
2000-01-20 John Sullivan <sullivan@eazel.com>
* libnautilus/gtkflist.c:
* libnautilus/gtkflist.h:
Move fields into details structure inside .c file.
2000-01-20 Jonathan Blandford <jrb@redhat.com>
* src/file-manager/fm-directory-view-list.c (column_clicked_cb):
more initialization to clean up an warning.
2000-01-20 Darin Adler <darin@eazel.com>
* src/gnome-icon-container.c:
(gnome_icon_container_xlate_selected):
Fixed a bug where dragging an icon would cause the "kbd_selected"
icon to scroll into view. Just passed FALSE instead of TRUE for
"schedule_visibility".
* libnautilus/nautilus-background.c:
(nautilus_background_draw_flat_box):
Tiny change, to fit our style rule against initializing.
2000-01-20 Jonathan Blandford <jrb@redhat.com>
* libnautilus/nautilus-background.c
(nautilus_background_draw_flat_box): fix warning.
2000-01-20 Elliot Lee <sopwith@redhat.com>
* src/ntl-uri-map.c: Async notification of navinfo - now we just need an async get_file_info call.
* src/ntl-view.[ch]: Better error handling.
* src/file-manager/fm-directory-view.c (display_selection_info): Send a 'selection change' request.
2000-01-19 Elliot Lee <sopwith@redhat.com>
* src/ntl-window-msgs.c: Totally rewrite the state changing machine. Now handles things slightly better.
* src/ntl-types.h: Remove requesting_view from the navigation info.
* src/ntl-window.h: Move all the state machine stuff into NautilusWindow itself.
* src/ntl-window.c: Update for new 'stop doing stuff' API.
Store icon positions as "x,y" in ICON_POSITION instead of storing ICON_X and ICON_Y. Take first step in moving the directory view to use the opaque NautilusDirectory and NautilusFile instead of using gnome-vfs directly. This will separate the controller from the model: FMDirectoryView is a controller and NautilusDirectory a model. * src/file-manager/fm-directory-view-icons.c: (add_to_icon_container): (fm_directory_view_icons_icon_moved_cb): Store icons positions as "x,y" in ICON_POSITION instead of storing separate numbers in ICON_X and ICON_Y. * libnautilus/nautilus-directory.h: libnautilus/nautilus-directory.c: (nautilus_directory_get_uri): Added a new call needed to replace fm_directory_view_get_uri. (nautilus_directory_get_file_metadata): (nautilus_directory_set_file_metadata): (nautilus_file_get_metadata): (nautilus_file_set_metadata): Moved the calls for getting and setting file metadata into the file objects. (nautilus_directory_new_file): (nautilus_file_get_info): Added temporary interfaces for the current situation where we're dealing with both NautilusFile and GnomeVFSFileInfo objects at once. (nautilus_directory_finalize): Detach and unref all the files when the directory is destroyed. (nautilus_file_unref): (nautilus_file_get_name): Implemented these functions now that we are using them. * src/file-manager/fm-directory-view.h: src/file-manager/fm-directory-view.c: (fm_directory_view_add_entry): (fm_directory_view_activate_entry): (display_selection_info): (fm_directory_view_get_selection): src/file-manager/fm-directory-view-icons.c: (add_to_icon_container): (fm_directory_view_icons_icon_moved_cb): (dm_directory_view_icons_add_entry): (fm_directory_view_icons_get_selection): (icon_container_activate_cb): src/file-manager/fm-directory-view-list.c: (add_to_flist): (fm_directory_view_list_add_entry): Change all the code to work with NautilusFile instead of GnomeVFSFileInfo, except for the parts of FMDirectoryView dealing with the directory_list. * src/file-manager/fm-directory-view.h: src/file-manager/fm-directory-view.c: (nautilus_file_date_as_string): (nautilus_file_size_as_string): (nautilus_file_type_as_string): libnautilus/nautilus-directory.h: libnautilus/nautilus-directory.c: (nautilus_file_get_date_as_string): (nautilus_file_get_size_as_string): (nautilus_file_get_type_as_string): Moved and renamed these functions and made them work on NautilusFile objects.
2000-01-20 21:23:35 +00:00
2000-01-20 Darin Adler <darin@eazel.com>
Store icon positions as "x,y" in ICON_POSITION instead of
storing ICON_X and ICON_Y.
Take first step in moving the directory view to use the opaque
NautilusDirectory and NautilusFile instead of using gnome-vfs
directly. This will separate the controller from the model:
FMDirectoryView is a controller and NautilusDirectory a model.
* src/file-manager/fm-directory-view-icons.c:
(add_to_icon_container):
(fm_directory_view_icons_icon_moved_cb):
Store icons positions as "x,y" in ICON_POSITION instead of storing
separate numbers in ICON_X and ICON_Y.
* libnautilus/nautilus-directory.h:
libnautilus/nautilus-directory.c:
(nautilus_directory_get_uri):
Added a new call needed to replace fm_directory_view_get_uri.
(nautilus_directory_get_file_metadata):
(nautilus_directory_set_file_metadata):
(nautilus_file_get_metadata):
(nautilus_file_set_metadata):
Moved the calls for getting and setting file metadata into the
file objects.
(nautilus_directory_new_file):
(nautilus_file_get_info):
Added temporary interfaces for the current situation where we're
dealing with both NautilusFile and GnomeVFSFileInfo objects at
once.
(nautilus_directory_finalize):
Detach and unref all the files when the directory is destroyed.
(nautilus_file_unref):
(nautilus_file_get_name):
Implemented these functions now that we are using them.
* src/file-manager/fm-directory-view.h:
src/file-manager/fm-directory-view.c:
(fm_directory_view_add_entry):
(fm_directory_view_activate_entry):
(display_selection_info):
(fm_directory_view_get_selection):
src/file-manager/fm-directory-view-icons.c:
(add_to_icon_container):
(fm_directory_view_icons_icon_moved_cb):
(dm_directory_view_icons_add_entry):
(fm_directory_view_icons_get_selection):
(icon_container_activate_cb):
src/file-manager/fm-directory-view-list.c:
(add_to_flist):
(fm_directory_view_list_add_entry):
Change all the code to work with NautilusFile instead of
GnomeVFSFileInfo, except for the parts of FMDirectoryView dealing
with the directory_list.
* src/file-manager/fm-directory-view.h:
src/file-manager/fm-directory-view.c:
(nautilus_file_date_as_string):
(nautilus_file_size_as_string):
(nautilus_file_type_as_string):
libnautilus/nautilus-directory.h:
libnautilus/nautilus-directory.c:
(nautilus_file_get_date_as_string):
(nautilus_file_get_size_as_string):
(nautilus_file_get_type_as_string):
Moved and renamed these functions and made them work on
NautilusFile objects.
2000-01-20 19:37:57 +00:00
2000-01-20 John Sullivan <sullivan@eazel.com>
* src/file-manager/fm-directory-view.c: (display_selection_info):
Made selection info in status bar use name of item when only one
item. Also reorganized copy/pasted code in this function.
2000-01-20 Darin Adler <darin@eazel.com>
Made backgrounds work better in the list view. Gradients still
won't work because the list view draws its background with calls
to gdk_draw_rectangle explicitly, and doesn't call the functions
in the style, so it can't be overridden.
* libnautilus/nautilus-background.c:
(nautilus_background_set_widget_style): Fix bug where the list
items were not highlighting properly. Set only the NORMAL and
ACTIVE background color. That way we don't screw up the SELECTED
and other background colors.
2000-01-20 Darin Adler <darin@eazel.com>
* libnautilus/nautilus-directory.c:
(nautilus_directory_get_file_metadata): Fix segfault that was
happening when viewing a folder without a metafile.
2000-01-19 Darin Adler <darin@eazel.com>
The list view now has a background color just like the
icon view does. Some more code could be saved, but that's
a refactoring for another time.
* libnautilus/gtkflist.c: Added support for receiving dragged
colors to set the background of the list.
* src/file-manager/fm-directory-view-list.c:
(fm_directory_view_list_initialize_class):
(fm_directory_view_list_clear):
(fm_directory_view_list_background_changed_cb): Added code to load
and save the background color from metadata.
* libnautilus/nautilus-background.c: Put the background color in
all the bg and base colors in the style instead of putting it only
in bg[GTK_STATE_NORMAL].
* libnautilus/nautilus-gtk-macros.h:
(NAUTILUS_DEFINE_CLASS_BOILERPLATE): Make sure that the macro only
evaluates the parent_class_type argument once, like it says in the
comment. (NAUTILUS_CALL_PARENT_CLASS): Fix this macro so it can
be used in places where an expression is expected.
* RENAMING: Added this file to list name changes we are
planning for the future.
* libnautilus/gtkflist.h: libnautilus/gtkflist.c:
src/explorer-location-bar.h: src/explorer-location-bar.c:
Minimized includes.
* src/ntl-index-panel.c:
src/file-manager/fm-directory-view-icons.c: Fixed some comments
and formatting.
2000-01-19 Darin Adler <darin@eazel.com>
Icon positions are now written out when you drag an icon,
and read in when you visit a directory. But the code then
immediately re-lays out the icons, so the position is lost!
* src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_icons_icon_moved_cb):
(fm_directory_view_icons_initialize): (add_container_icon): Save
icon position when an icon is moved. Get icon position when an
icon is first created.
* libnautilus/nautilus-directory.c:
(nautilus_directory_get_metadata_from_node):
(nautilus_directory_get_metadata):
(nautilus_directory_create_metafile_tree_root):
(nautilus_directory_get_metadata):
(nautilus_directory_set_metadata):
(nautilus_directory_get_file_metadata):
(nautilus_directory_set_file_metadata): Added the routines to get
and set metadata for individual files.
* libnautilus/nautilus-string.h: libnautilus/nautilus-string.c:
(nautilus_eat_strcmp): (nautilus_string_to_int):
(nautilus_eat_string_to_int): Made new string functions that free
the existing strings, and a function to convert an int to a
string.
* libnautilus/gnome-icon-container.h:
libnautilus/gnome-icon-container.c: (move_icon): (class_init):
(handle_icon_button_press): Added context_click_background and
icon_moved signals, and renamed context_click to
context_click_icon.
* configure.in: Turned -Wunused back on. I had to turn -W off,
but I think it's worth it.
2000-01-19 21:02:01 +00:00
2000-01-19 John Sullivan <sullivan@eazel.com>
* src/file-manager/fm-directory-view.c:
Added #include <libgnomevfs/gnome-vfs-file-info.h>
(fm_directory_view_populate), (display_pending_entries):
Bump refcount on file info before adding it to directory.
(fm_directory_view_load_uri): Destroy directory list
before setting it to NULL. With previous change, this
should prevent leaking GnomeVFSFileInfos and their
lists.
2000-01-19 Darin Adler <darin@eazel.com>
* libnautilus/nautilus-directory.c: (nautilus_directory_finalize):
(nautilus_directory_try_to_read_metafile):
(nautilus_directory_read_metafile):
(nautilus_directory_try_to_write_metafile):
(nautilus_directory_write_metafile):
(nautilus_directory_construct_alternate_metafile_uri):
(nautilus_directory_new): After Andy explained his change to me, I
realized that it would always write the metafile in the alternate
place if there was no pre-existing metafile. So I changed the
logic. The new rule is: read the metafile from the alternate
location first. If we find it there, write it back
there. Otherwise, try to write in the directory itself. If that
fails, write it in the alternate location instead.
* libnautilus/nautilus-directory.c:
(nautilus_directory_get_metadata): Allow get_metadata on a NULL
NautilusDirectory and return NULL for data.
Allow changing the background of the icon view by dropping colors on the icon view. * libnautilus/gnome-icon-container-dnd.h: libnautilus/gnome-icon-container-dnd.c: (gnome_icon_container_position_shadow): (drag_data_received_cb): (gnome_icon_container_ensure_drag_data): (drag_motion_cb): (drag_drop_cb): (gnome_icon_container_receive_dropped_icons): (gnome_icon_container_free_drag_data): (drag_leave_cb): Added support for receiving dropped colors to change the background of a GnomeIconContainer. * src/file-manager/fm-directory-view-icons.c: (fm_directory_view_icons_initialize_class): (fm_directory_view_icons_clear): (fm_directory_view_icons_background_changed_cb): Added code to load and save the background color from metadata. * libnautilus/gdk-extensions.c: (nautilus_gradient_new): Changed nautilus_gradient_new to handle NULLs in the same way that the rest of the gradient functions do instead of NULL being an illegal input value. * src/file-manager/fm-directory-view.h: src/file-manager/fm-directory-view.c: (fm_directory_view_initialize): (fm_directory_view_destroy): (fm_directory_view_get_model): (fm_directory_view_load_uri): Added a NautilusDirectory object to each directory view, accessed by subclasses with a call to fm_directory_view_get_model. * libnautilus/nautilus-gtk-extensions.h: libnautilus/nautilus-gtk-extensions.c: (gnome_icon_container_dropped_icon_feedback): (nautilus_gdk_selection_data_copy_deep): Added deep versions of these GtkSelectionData functions. * libnautilus/nautilus-gtk-macros.h: (NAUTILUS_DEFINE_GET_TYPE_FUNCTION): (NAUTILUS_DEFINE_CLASS_BOILERPLATE): Added definition and initialization of the parent_class global to NAUTILUS_DEFINE_GET_TYPE_FUNCTION and renamed it to NAUTILUS_DEFINE_CLASS_BOILERPLATE. * libnautilus/nautilus-background-canvas-group: (nautilus_background_canvas_group_initialize_class): libnautilus/nautilus-background.c: (nautilus_background_initialize_class): libnautilus/nautilus-directory.c: (nautilus_directory_initialize_class): src/ntl-index-panel.c: (nautilus_index_panel_initialize_class): src/file-manager/fm-directory-view-icons.c: (fm_directory_view_icons_initialize_class): src/file-manager/fm-directory-view-list.c: (fm_directory_view_list_initialize_class): src/file-manager/fm-directory-view.c: (fm_directory_view_initialize_class): Take advantage of the new NAUTILUS_DEFINE_CLASS_BOILERPLATE and get rid of existing code to set up parent_class. * libnautilus/gnome-icon-container-dnd.h: libnautilus/gnome-icon-container-dnd.c: libnautilus/gnome-icon-container-layout.h: libnautilus/gnome-icon-container-layout.c: libnautilus/gnome-icon-container.c: Minimized includes.
2000-01-19 18:34:33 +00:00
2000-01-19 Darin Adler <darin@eazel.com>
Allow changing the background of the icon view by dropping colors
on the icon view.
* libnautilus/gnome-icon-container-dnd.h:
libnautilus/gnome-icon-container-dnd.c:
(gnome_icon_container_position_shadow): (drag_data_received_cb):
(gnome_icon_container_ensure_drag_data): (drag_motion_cb):
(drag_drop_cb): (gnome_icon_container_receive_dropped_icons):
(gnome_icon_container_free_drag_data): (drag_leave_cb): Added
support for receiving dropped colors to change the background of a
GnomeIconContainer.
* src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_icons_initialize_class):
(fm_directory_view_icons_clear):
(fm_directory_view_icons_background_changed_cb): Added code to
load and save the background color from metadata.
* libnautilus/gdk-extensions.c: (nautilus_gradient_new): Changed
nautilus_gradient_new to handle NULLs in the same way that the
rest of the gradient functions do instead of NULL being an illegal
input value.
* src/file-manager/fm-directory-view.h:
src/file-manager/fm-directory-view.c:
(fm_directory_view_initialize): (fm_directory_view_destroy):
(fm_directory_view_get_model): (fm_directory_view_load_uri): Added
a NautilusDirectory object to each directory view, accessed by
subclasses with a call to fm_directory_view_get_model.
* libnautilus/nautilus-gtk-extensions.h:
libnautilus/nautilus-gtk-extensions.c:
(gnome_icon_container_dropped_icon_feedback):
(nautilus_gdk_selection_data_copy_deep): Added deep versions of
these GtkSelectionData functions.
* libnautilus/nautilus-gtk-macros.h:
(NAUTILUS_DEFINE_GET_TYPE_FUNCTION):
(NAUTILUS_DEFINE_CLASS_BOILERPLATE): Added definition and
initialization of the parent_class global to
NAUTILUS_DEFINE_GET_TYPE_FUNCTION and renamed it to
NAUTILUS_DEFINE_CLASS_BOILERPLATE.
* libnautilus/nautilus-background-canvas-group:
(nautilus_background_canvas_group_initialize_class):
libnautilus/nautilus-background.c:
(nautilus_background_initialize_class):
libnautilus/nautilus-directory.c:
(nautilus_directory_initialize_class): src/ntl-index-panel.c:
(nautilus_index_panel_initialize_class):
src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_icons_initialize_class):
src/file-manager/fm-directory-view-list.c:
(fm_directory_view_list_initialize_class):
src/file-manager/fm-directory-view.c:
(fm_directory_view_initialize_class): Take advantage of the new
NAUTILUS_DEFINE_CLASS_BOILERPLATE and get rid of existing code to
set up parent_class.
* libnautilus/gnome-icon-container-dnd.h:
libnautilus/gnome-icon-container-dnd.c:
libnautilus/gnome-icon-container-layout.h:
libnautilus/gnome-icon-container-layout.c:
libnautilus/gnome-icon-container.c: Minimized includes.
2000-01-18 Andy Hertzfeld <andy@eazel.com>
* libnautilus/gnome-icon-container.c
made icon centered in cell by setting "x_set" pixbuf property so
it listens to our offset also, adjusted x_offset constant
* libnautilus/gnome-icon-container-dnd.c
made shadow be centered properly by taking difference between
cellwidth and iconwidth into account
2000-01-18 Ettore Perazzoli <ettore@helixcode.com>
* src/file-manager/dfos-xfer.c (xfer_info_destroy): Removed `#if
0'ed out function.
* src/ntl-uri-map.c (nautilus_navinfo_new): Use
`gnome_vfs_file_info_unref()' instead of
`gnome_vfs_file_info_destroy()'.
2000-01-18 Andy Hertzfeld <andy@eazel.com>
* libnautilus/gnome-icon-container-private.h:
added "button_down_time" field to private data structure
* libnautilus/gnome-icon-container.c
made it not activate objects if the button was held down too long
by remember the mouse down time and comparing it with the up time
2000-01-18 John Sullivan <sullivan@eazel.com>
* src/file-manager/fm-directory-view.c:
(fm_directory_view_load_uri): Set directory list to NULL
but don't destroy it; this fixes crash entering a directory
and then going up. Will ask Ettore about real fix.
2000-01-18 John Sullivan <sullivan@eazel.com>
* src/ntl-window-msgs.c:
(nautilus_window_refresh_title): Sets the window title to
Nautilus: x, where x is short name of current location.
(nautilus_window_change_location_internal): Call
nautilus_window_refresh_title.
2000-01-18 John Sullivan <sullivan@eazel.com>
* src/file-manager/fm-directory-view.c:
(display_selection_info): Call selection "items" rather than
"files" because users distinguish directories from files.
2000-01-18 John Sullivan <sullivan@eazel.com>
* src/file-manager/fm-directory-view.h:
(enum _FMDirectoryViewSortType): added FM_DIRECTORY_VIEW_SORT_NONE
and FM_DIRECTORY_VIEW_SORT_BYMTIME
(fm_directory_view_sort): added reverse_sort parameter.
(nautilus_file_date_as_string):
(nautilus_file_size_as_string): Changed parameter for these two
functions to be GnomeVFSFileInfo so they can handle special cases better.
(nautilus_file_type_as_string): New function
* src/file-manager/fm-directory-view.c
(stop_load): Removed code resetting directory_list and current_position.
This was the wrong place for it, and resetting directory_list was leaking.
(directory_load_cb): Changed commented assignment to assert.
(fm_directory_view_load_uri): Reset directory_list (without leaking old
value) and current_position here.
(fm_directory_view_sort): Pass through new reverse_sort parameter to
gnome_vfs_directory_view_sort; add new case for
FM_DIRECTORY_VIEW_SORT_BYMTIME; don't put directories first when sorting
by name.
(nautilus_file_date_as_string): Now takes a GnomeVFSFileInfo pointer
instead of a time_t (assumes mtime, with comment explaining why).
(nautilus_file_size_as_string): Now takes a GnomeVFSFileInfo pointer
instead of a size; uses this to special-case "--" for directory size.
(nautilus_file_type_as_string): New function, special-cases directories
to return "directory", otherwise returns mime_type.
* src/file-manager/fm-directory-view-list.h
Added private details structure to FMDirectoryViewList.
* src/file-manager/fm-directory-view-list.c
Added _FMDirectoryViewListDetails struct, containing sort_type and
sort_reversed.
(fm_directory_view_initialize): initialize details struct.
(column_clicked_cb): New function, sorts list by clicked column.
If list already sorted by that column, reverses sort. Still need
visual indicator of sort direction.
(create_flist): Added Type column, tweaked column widths, added
signal connection for "click_column"
(add_to_flist): now passes GnomeVFSFileInfo to
nautilus_file_size_as_string and nautilus_file_date_as_string;
uses new nautilus_file_type_as_string for type column.
2000-01-18 20:44:05 +00:00
2000-01-18 Andy Hertzfeld <andy@eazel.com>
* libnautilus/nautilus-directory:
* made reading metafile from directory where we don't have write
permissions work by changing error-check to look in common place on
any error instead of just access_denied.
2000-01-18 20:44:05 +00:00
2000-01-18 Andy Hertzfeld <andy@eazel.com>
* libnautilus/nautilus-directory.c:
2000-01-18 20:44:05 +00:00
fixed bug caused by Elliot where he used alloca but forgot to remove g_free
2000-01-18 Elliot Lee <sopwith@redhat.com>
* libnautilus/nautilus-gtk-macros.h: Since the prototypes for
GtkObjectInitFunc and GtkClassInitFunc just have a 'gpointer' for the args,
cast the given values to these function types, so that people can use the actual
pointer types as arguments without receiving a warning.
* src/ntl-index-panel.c: Change to match. Also set
object_klass->destroy & object_klass->finalize to point to our
implementation. Also remove unused variables
(nautilus_index_panel_initialize,
nautilus_index_panel_set_up_label).
* libnautilus/nautilus-background.c, src/ntl-window-msgs.c,
src/ntl-window.c, src/file-manager/fm-directory-icons.c: Remove
unused variables.
* src/ntl-window.h: Add a variable (unused) for future handling of content view loading.
* libnautilus/libnautilus.h: Add an interim g_alloca.
* libnautilus/nautilus-directory.c: Clean up a bit further, by
removing the need for another if(), and using g_alloca instead of
g_malloc.
Added first cut at code to put metafiles in the user's home directory if * libnautilus/nautilus-directory.c: (nautilus_directory_read_metafile): (nautilus_directory_try_to_read_metafile): (nautilus_directory_write_metafile): (nautilus_directory_try_to_write_metafile): (nautilus_directory_switch_to_alternate_metafile_uri): (nautilus_directory_escape_slashes): (nautilus_make_directory_and_parents): Added first cut at code to put metafiles in the user's home directory if the directory is not accessible and you can't read and write a metafile in the directory itself. We'll have to refine this later to handle cases where you end up with two metafiles. * libnautilus/Makefile.am: libnautilus/nautilus-debug.h: libnautilus/nautilus-debug.c: Took trick for getting into the debugger and put it into a public header file so it can be used outside of the nautilus executable. * src/ntl-main.c: (stop_in_debugger): (nautilus_stop_after_default_log_handler): (main): Use the new calls from libnautilus to set up the drop into debugger for criticals and warnings. * src/file-manager/fm-main.c: (main): Minimized includes and used the new calls from libnautilus to set up the drop into debugger for criticals and warnings. * src/ntl-uri-map.c: (nautilus_navinfo_add_mapping): src/ntl-window.c: (nautilus_window_constructed): src/file-manager/fm-directory-view.c: (fm_directory_view_initialize): (fm_directory_view_destroy): (notify_location_change_cb): (stop_location_change_cb): (fm_directory_view_sort): Removed some messages that aren't so useful. * libnautilus/ntl-view-frame.h: Minimized includes. * libnautilus/ntl-view-frame.c: Include "ntl-view-frame.h" first so it tests to see that it has sufficient includes in it. * src/ntl-view.c: (nautilus_view_load_client): Changed function so that NULL for an iid is allowed and simply results in a failed load instead of being illegal. * src/ntl-window-msgs.c: (nautilus_window_change_location_internal): src/ntl-window.c: (nautilus_window_up): Got rid of calls to gnome_vfs_uri_destroy; use gnome_vfs_uri_unref instead since it's safer and Federico is getting rid of gnome_vfs_uri_destroy. * src/file-manager/fm-directory-view-icons.h: src/file-manager/fm-directory-view-icons.c: (fm_directory_view_icons_new): src/file-manager/fm-directory-view-list.h: src/file-manager/fm-directory-view-list.c: (fm_directory_view_list_new): src/file-manager/fm-directory-view.h: src/file-manager/fm-directory-view.c: (fm_directory_view_new): Minimized includes and got rid of the unused _new functions. * libnautilus/nautilus-directory.h: Added a missing 2000 copyright date.
2000-01-18 18:55:36 +00:00
2000-01-18 Darin Adler <darin@eazel.com>
* libnautilus/nautilus-directory.c:
(nautilus_directory_read_metafile):
(nautilus_directory_try_to_read_metafile):
(nautilus_directory_write_metafile):
(nautilus_directory_try_to_write_metafile):
(nautilus_directory_switch_to_alternate_metafile_uri):
(nautilus_directory_escape_slashes):
(nautilus_make_directory_and_parents): Added first cut at code to
put metafiles in the user's home directory if the directory is not
accessible and you can't read and write a metafile in the
directory itself. We'll have to refine this later to handle cases
where you end up with two metafiles.
* libnautilus/Makefile.am: libnautilus/nautilus-debug.h:
libnautilus/nautilus-debug.c: Took trick for getting into the
debugger and put it into a public header file so it can be used
outside of the nautilus executable.
* src/ntl-main.c: (stop_in_debugger):
(nautilus_stop_after_default_log_handler): (main): Use the new
calls from libnautilus to set up the drop into debugger for
criticals and warnings.
* src/file-manager/fm-main.c: (main): Minimized includes and used
the new calls from libnautilus to set up the drop into debugger
for criticals and warnings.
* src/ntl-uri-map.c: (nautilus_navinfo_add_mapping):
src/ntl-window.c: (nautilus_window_constructed):
src/file-manager/fm-directory-view.c:
(fm_directory_view_initialize): (fm_directory_view_destroy):
(notify_location_change_cb): (stop_location_change_cb):
(fm_directory_view_sort): Removed some messages that aren't so
useful.
* libnautilus/ntl-view-frame.h: Minimized includes.
* libnautilus/ntl-view-frame.c: Include "ntl-view-frame.h" first
so it tests to see that it has sufficient includes in it.
* src/ntl-view.c: (nautilus_view_load_client): Changed function so
that NULL for an iid is allowed and simply results in a failed
load instead of being illegal.
* src/ntl-window-msgs.c:
(nautilus_window_change_location_internal): src/ntl-window.c:
(nautilus_window_up): Got rid of calls to gnome_vfs_uri_destroy;
use gnome_vfs_uri_unref instead since it's safer and Federico is
getting rid of gnome_vfs_uri_destroy.
* src/file-manager/fm-directory-view-icons.h:
src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_icons_new):
src/file-manager/fm-directory-view-list.h:
src/file-manager/fm-directory-view-list.c:
(fm_directory_view_list_new):
src/file-manager/fm-directory-view.h:
src/file-manager/fm-directory-view.c: (fm_directory_view_new):
Minimized includes and got rid of the unused _new functions.
* libnautilus/nautilus-directory.h: Added a missing 2000 copyright
date.
2000-01-17 John Sullivan <sullivan@eazel.com>
First steps towards making the list view non-degenerate.
* src/file-manager/fm-directory-view.h:
* src/file-manager/fm-directory-view.c:
(nautilus_file_date_as_string): New function, returns string suitable
for displaying in a list view column.
(nautilus_file_size_as_string): New function, calls newly-publicized
gnome_vfs_file_size_to_string.
(display_selection_info): Now calls gnome_vfs_file_size_to_string
instead of redoing the string-creation code here.
* src/file-manager/fm-directory-view-list.c
(create_flist): Creates new columns for icon, size, and mod date.
(add_to_flist): Fills columns for size & mod date. Icon column
is empty for the moment. Columns do not yet sort.
2000-01-17 Andy Hertzfeld <andy@eazel.com>
*libnautilus/gnome-icon-container-dnd.c:
made dragging work right by using gdk_pixbuf_render_pixmap_and_mask
to make a pixmap and mask to pass to the gtk dragging machinery
*libnautilus/gnome-icon-container.c:
changed xoffset constant for the icon mode positioning to make the
feedback box line up with the icon.
2000-01-16 Andy Hertzfeld <andy@eazel.com>
*libnautilus/gnome-icon-container-dnd.c:
made dragging use an image of the canvas item dragged
still disabled, though, because it's not handling the mask yet
2000-01-16 Andy Hertzfeld <andy@eazel.com>
*libnautilus/gnome-icon-container-private.h:
added "single_click_mode" boolean
*libnautilus/gnome-icon-container.h
made single-click open optionally work by adding code in
button_release_event to activate the icon if appropriate
enabled single-click mode by default
*libnautilus/gnome-icon-container-dnd.c
made dragging to desktop and else work by cleaning up code in set_uri_list_selection
did work toward better dragging feedback using an image but didn't finish that yet
2000-01-15 Andy Hertzfeld <andy@eazel.com>
*libnautilus/gnome-icon-container-dnd.c:
made dragging files within a window actually work graphically, and set the stage for dragging between windows
made drag_leave_cb no longer delete the selection_list
made drag_data_received_cb delete selection if present instead of asserting it's gone
made drag_drop_cb use the selection_list to determine the directory we're dragging from,
if it's the same, move within the window, otherwise copy between (coming soon)
didn't update positions in the metafile yet
2000-01-14 John Sullivan <sullivan@eazel.com>
* src/file-manager/fm-directory-view.c:
(display_selection_info):
Fixed a killer typo that caused selection to crash.
2000-01-14 John Sullivan <sullivan@eazel.com>
Finished refactoring FMDirectoryView and subclasses. I
don't plan any more major reworking on these files, so
feel free to change things without fear of stomping on
me.
* src/file-manager/fm-directory-view.c:
* src/file-manager/fm-directory-view.h:
* src/file-manager/fm-directory-view-icons.c:
* src/file-manager/fm-directory-view-icons.h:
* src/file-manager/fm-directory-view-list.c:
* src/file-manager/fm-directory-view-list.h:
Moved icon_layout and icons_not_in_layout fields from
FMDirectoryView to FMDirectoryViewIcons (where they hide
inside a details structure in fm-directory-view-icons.c)
Commented .h files and all public functions in .c files.
Removed unnecessary #includes.
Changed signatures on many static functions in subclasses
to take subclass type instead of superclass type.
(display_selection_info_idle_cb):
(fm_directory_view_get_selection):
(fm_directory_view_icons_get_selection):
(fm_directory_view_list_get_selection):
(fm_directory_view_notify_selection_changed):
New functions used to handle subclasses telling
superclass about the selection, so superclass can
display info about it.
(display_icon_container_selection_info_idle_cb):
(display_flist_selection_info_idle_cb): Removed these
old functions in favor of new cleaner mechanism.
(flist_activate_cb), (icon_container_activate_cb): Moved
common code into new superclass function...
(fm_directory_view_activate_entry): New home of that common
code.
* src/file-manager/fm-directory-view.c:
* src/file-manager/fm-directory-view.h:
Moved remaining fields of FMDirectoryView inside a private
details structure so they can change without affecting clients.
(fm_directory_view_get_uri): (fm_directory_view_get_view_frame):
New functions to use instead of peeking at structure directly.
(init): (class_init): (fm_directory_view_get_type): Renamed
the former two functions and removed the latter while
deploying NAUTILUS_DEFINE_GET_TYPE_FUNCTION macro.
* src/file-manager/fm-main.c:
(make_obj): Use fm_directory_view_get_view_frame() where it
had been peeking at structure directly.
2000-01-14 Darin Adler <darin@eazel.com>
Fixed our handling of warnings and criticals.
* src/ntl-main.c: Added new functions that stop in the debugger
when you hit a g_warning or a critical error, only if the
environment variable NAUTILUS_DEBUG is set. This is better than
the way the old code made everything fatal, since it doesn't do
anything if the debugger isn't running.
2000-01-14 23:36:00 +00:00
2000-01-14 Darin Adler <darin@eazel.com>
Turned on gradients for backgrounds.
* src/ntl-index-panel.c:
(nautilus_index_panel_drag_data_received): Use the new
accept_dropped_color function in NautilusBackground instead of
code in here. (nautilus_index_panel_background_changed):
(nautilus_index_panel_set_up_info): Save background to metadata
when the NautilusBackground object emits the changed signal.
* libnautilus/nautilus-background.h:
libnautilus/nautilus-background.c:
(nautilus_background_accept_dropped_color): Moved logic about
dropping a color coupon to change the background into the
NautilusBackground class. This includes a first cut at the rules
about gradients.
* libnautilus/nautilus-background.c:
(nautilus_background_get_color): Implemented this missing
function. It's used by the code in index panel now to save the
current background.
* libnautilus/nautilus-background.c:
(nautilus_background_draw_flat_box): Implemented gradient fills
through the GtkStyle subclass.
* src/ntl-main.c: (main): Made criticals and warnings be always
fatal. Next step is to make them drop into the debugger, but not
result in a core dump if the debugger is not running.
2000-01-14 Darin Adler <darin@eazel.com>
* src/ntl-index-panel.c: (nautilus_index_panel_set_up_label):
Changed code to use the new gnome_vfs_uri_extract_short_name
instead of its own private function.
2000-01-14 19:36:38 +00:00
2000-01-14 Darin Adler <darin@eazel.com>
First cut at some actual saving of metadata.
Neither the interface nor the implementation is great yet.
But it's a start.
* libnautilus/Makefile.am:
libnautilus/nautilus-directory.h:
libnautilus/nautilus-directory.c:
libnautilus/nautilus-lib-self-check-functions.h:
libnautilus/nautilus-lib-self-check-functions.c:
src/file-manager/Makefile.am:
src/file-manager/fm-directory-protected.h:
src/file-manager/fm-directory.h:
src/file-manager/fm-directory.c:
src/file-manager/fm-vfs-directory.h:
src/file-manager/fm-vfs-directory.c:
Moved the old FMDirectory class into the library and named it
NautilusDirectory. Added functions for reading and writing
metadata.
* src/ntl-index-panel.c: Added the code to save the index panel's
background color in metadata.
* libnautilus/Makefile.am: Added gnome-vfs and gnome-xml,
since the new code uses them.
* libnautilus/nautilus-self-checks.h:
libnautilus/nautilus-lib-self-check-functions.h:
libnautilus/nautilus-lib-self-check-functions.c:
src/nautilus-self-check-functions.h:
src/nautilus-self-check-functions.c:
Added macros to the self-check framework so the list of self check
functions appears in exactly one place for each directory/module.
* src/ntl-index-panel.h: src/ntl-index-panel.c: Moved the fields
of the index panel inside a private details structure so they can
change without affecting clients.
* libnautilus/nautilus-background.c: Just some reformatting.
2000-01-13 John Sullivan <sullivan@eazel.com>
More work pushing code from FMDirectoryView into subclasses.
Almost done now.
* src/file-manager/fm-directory-view.h:
Removed enum _FMDirectoryViewMode and its typedef.
Removed field entries_to_display.
Removed transition section holding function prototypes that
were on their way into subclasses.
(fm_directory_view_is_valid_mode): Removed.
(fm_directory_view_get_mode): Removed.
(fm_directory_view_set_mode): Removed.
(fm_directory_view_begin_adding_entries): New function & signal.
(fm_directory_view_add_entry): New function & signal.
(fm_directory_view_done_adding_entries): New function & signal.
(fm_directory_view_done_sorting_entries): New function & signal.
(fm_directory_view_begin_loading): New function & signal.
(fm_directory_view_display_selection_info): Newly exposed function.
* src/file-manager/fm-directory-view.c:
Removed some now-unnecessary #includes.
Added constants for new signals to enum.
Removed global variable for icon cache in favor of already-extant
fm_get_current_icon_cache().
Removed all references to entries_to_display.
(display_selection_info): Renamed to
fm_directory_view_display_selection_info now that it's public.
(view_has_icon_container): Removed.
(get_icon_container): Moved into subclass FMDirectoryViewIcons.
(add_to_icon_container): Moved into subclass FMDirectoryViewIcons.
(load_icon_container): Moved into subclass FMDirectoryViewIcons.
(display_icons_not_in_layout): Moved into subclass FMDirectoryViewIcons.
(setup_base_uri): Moved into subclass FMDirectoryViewIcons (and renamed
to set_up_base_uri).
(view_has_flist): Removed.
(get_flist): Moved into subclass FMDirectoryViewList.
(add_to_flist): Moved into subclass FMDirectoryViewList.
(class_init): Signal initialization code for begin_adding_entries,
add_entry, done_adding_entries, done_sorting_entries, and begin_loading.
(init): Removed mode-setting line.
(display_pending_entries): Replaced the bulk of this function with three
new signals: begin_adding_entries, add_entry, done_adding_entries. The
loop structure and GnomeVFSFileInfo retrieving part remains.
(directory_load_cb): Deployed new signal begin_loading where setup_base_uri
used to be.
(fm_directory_view_is_valid_mode): Removed.
(fm_directory_view_get_mode): Removed.
(fm_directory_view_set_mode): Removed.
(fm_directory_view_begin_adding_entries): New function, emits signal.
(fm_directory_view_add_entry): New function, emits signal.
(fm_directory_view_done_adding_entries): New function, emits signal.
(fm_directory_view_done_sorting_entries): New function, emits signal.
(fm_directory_view_begin_loading): New function, emits signal.
(fm_directory_view_sort): Replaced some icon-container-specific
code with fm_directory_view_done_sorting_entries().
* src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_icons_initialize_class): Wired up signal handlers
for add_entry, done_adding_entries, done_sorting_entries, and begin_loading.
(fm_directory_view_icons_initialize): Removed set_mode call.
(display_icons_not_in_layout): Moved here from superclass FMDirectoryView.
(get_icon_container): Moved here from superclass FMDirectoryView.
(add_to_icon_container): Moved here from superclass FMDirectoryView.
(load_icon_container): Moved here from superclass FMDirectoryView.
(set_up_base_uri): Moved here from superclass FMDirectoryView.
(fm_directory_view_icons_add_entry): New signal handler function, code
taken and simplified from superclass FMDirectoryView.
(fm_directory_view_icons_done_adding_entries): New signal handler
function, code taken and simplified from superclass FMDirectoryView.
(fm_directory_view_icons_done_sorting_entries): New signal handler
function, code taken and simplified from superclass FMDirectoryView.
(fm_directory_view_icons_begin_loading): New signal handler function,
code taken and simplified from superclass FMDirectoryView.
* src/file-manager/fm-directory-view-list.c:
(fm_directory_view_list_initialize_class): Wired up signal handlers
for begin_adding_entries, add_entry, and done_adding_entries
(fm_directory_view_list_initialize): Removed set_mode call.
(get_flist): Moved here from superclass FMDirectoryView.
(add_to_flist): Moved here from superclass FMDirectoryView.
(fm_directory_view_list_begin_adding_entries): New signal handler
function, code taken and simplified from superclass FMDirectoryView.
(fm_directory_view_list_add_entry): New signal handler function, code
taken and simplified from superclass FMDirectoryView.
(fm_directory_view_list_done_adding_entries): New signal handler
function, code taken and simplified from superclass FMDirectoryView.
2000-01-13 John Sullivan <sullivan@eazel.com>
* libnautilus/nautilus-gtk-macros.h: Defined macros
for use when a signal must be overridden by subclasses.
* src/file-manager/fm-directory-view.c: Deployed these
new macros for the "clear" signal.
NAUTILUS_IMPLEMENT_MUST_OVERRIDE_SIGNAL is outside any
function, and
(class_init): NAUTILUS_MUST_OVERRIDE_SIGNAL is in here.
(fm_directory_view_real_clear): Eliminated this in favor
of the above macros.
* src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_icons_get_type): Replaced function with
NAUTILUS_DEFINE_GET_TYPE_FUNCTION macro.
(fm_directory_view_icons_init): Renamed to
fm_directory_view_icons_initialize and standardized parameters
to work with NAUTILUS_DEFINE_GET_TYPE_FUNCTION macro.
(fm_directory_view_icons_class_init): Renamed to
fm_directory_view_icons_initialize_class and standardized
parameters to work with NAUTILUS_DEFINE_GET_TYPE_FUNCTION macro.
(fm_directory_view_icons_destroy): Deployed
NAUTILUS_CALL_PARENT_CLASS macro.
* src/file-manager/fm-directory-view-list.c:
(fm_directory_view_list_get_type): Replaced function with
NAUTILUS_DEFINE_GET_TYPE_FUNCTION macro.
(fm_directory_view_list_init): Renamed to
fm_directory_view_list_initialize and standardized parameters
to work with NAUTILUS_DEFINE_GET_TYPE_FUNCTION macro.
(fm_directory_view_list_class_init): Renamed to
fm_directory_view_list_initialize_class and standardized
parameters to work with NAUTILUS_DEFINE_GET_TYPE_FUNCTION macro.
(fm_directory_view_list_destroy): Deployed
NAUTILUS_CALL_PARENT_CLASS macro.
2000-01-12 John Sullivan <sullivan@eazel.com>
More work at pushing appropriate fm_directory_view code
into subclasses.
* src/file-manager/fm-directory-view.c:
(class_init): Register "clear" signal, make
fm_directory_view_real_clear be default handler.
(fm_directory_view_real_clear): New function, does
nothing but complain when it's called. (I'm going to
replace this with a debug-only mechanism soon.)
(fm_directory_view_clear): New function, emits "clear" signal.
(fm_directory_view_load_uri): Replaced "if icons clear this way,
if list clear that way" code with call to fm_directory_view_clear.
(mode_uses_flist): Eliminated, wrapped into only remaining caller
view_has_flist (which will itself go away soon).
(mode_uses_icon_container): Eliminated, wrapped into only remaining caller
view_has_icon_container (which will itself go away soon).
* src/file-manager/fm-directory-view-icons.c:
(fm_directory_view_icons_clear): New function, erases icon container.
(fm_directory_view_icons_init): Replace fm_directory_view's
"clear" signal handler with fm_directory_view_icons_clear
(fm_directory_view_icons_get_icon_layout): Moved to here.
(fm_directory_view_icons_set_icon_layout): Moved to here.
(fm_directory_view_icons_line_up_icons): Moved to here.
* src/file-manager/fm-directory-view-list.c:
(fm_directory_view_list_clear): New function, erases list contents.
(fm_directory_view_list_init): Replace fm_directory_view's
"clear" signal handler with fm_directory_view_list_clear
* src/file-manager/fm-directory-view.h:
(fm_directory_view_clear): Added "clear" signal, and
fm_directory_view_clear prototype.
(fm_directory_view_icons_get_icon_layout): Moved out of here.
(fm_directory_view_icons_set_icon_layout): Moved out of here.
(fm_directory_view_icons_line_up_icons): Moved out of here.
* src/file-manager/fm-directory-view-icons.h:
(fm_directory_view_icons_get_icon_layout): Moved to here.
(fm_directory_view_icons_set_icon_layout): Moved to here.
(fm_directory_view_icons_line_up_icons): Moved to here.
2000-01-12 John Sullivan <sullivan@eazel.com>
* src/ntl-window-msgs.c (nautilus_window_load_content_view_menu):
Made option menu say "View as Icons" (e.g.) instead of just "Icons"
2000-01-11 Andy Hertzfeld <andy@eazel.com>
* src/ntl-window:
added a debug menu, and it's first item to show a color picker to test dropping colors
2000-01-11 John Sullivan <sullivan@eazel.com>
Started moving icon-specific and list-specific code
into the subclasses. As a transition step, added some
private prototypes to the .h file (clearly marked).
* src/file-manager/fm-directory-view.c:
(setup_flist), (setup_icon_container): eliminated completely.
(display_icon_container_selection_info_idle_cb),
(icon_container_selection_changed_cb), (icon_container_activate_cb),
(create_icon_container), (display_flist_selection_info_idle_cb),
(flist_activate_cb), (flist_selection_changed_cb),
(create_flist): moved out.
(fm_directory_view_set_mode): removed the guts, which are now
in the init functions for the subclasses; now just sets the
field (which will go away eventually).
* src/file-manager/fm-directory-view.h:
(add_to_flist), (display_selection_info), (get_flist),
(get_icon_container), (load_icon_container): temporarily
added to .h file.
* src/file-manager/fm-directory-view-icons.c:
(display_icon_container_selection_info_idle_cb),
(icon_container_selection_changed_cb), (icon_container_activate_cb),
(create_icon_container): moved in.
(fm_directory_view_icons_init): Now creates icon_container here instead of
in fm_directory_view_set_mode (which will eventually go away).
* src/file-manager/fm-directory-view-list.c:
(display_flist_selection_info_idle_cb), (flist_activate_cb),
(flist_selection_changed_cb), (create_flist): moved in.
(fm_directory_view_list_init): Now creates flist here instead of
in fm_directory_view_set_mode (which will eventually go away).
* src/ntl-window.c:
(real_nautilus_window_set_content_view): Renamed to
nautilus_window_real_set_content_view. Also added
self as an author.
2000-01-11 Darin Adler <darin@eazel.com>
NautilusBackground is now used for the index panel background.
* libnautilus/nautilus-background.c:
(nautilus_background_attach_to_canvas):
(nautilus_get_widget_background):
(nautilus_gtk_style_get_default_class):
(nautilus_gdk_window_update_sizes):
(nautilus_background_draw_flat_box):
(nautilus_background_get_gtk_style_class):
(nautilus_background_set_widget_style):
(nautilus_background_set_up_canvas):
(nautilus_widget_background_changed):
(nautilus_get_widget_background):
Added new code that changes the background of a widget by
modifying the GtkStyle. For solid colors and tiled images we
can just modify the GtkStyle. For gradients we need to make
a GtkStyle subclass.
* libnautilus/nautilus-background.h:
(nautilus_background_attach_to_canvas):
(nautilus_get_widget_background):
Changed the old interface that was canvas-specific, to a new one
that allows attacking a background to any widget.
* src/ntl-index-panel.h:
Now that the background is attached to the widget, we don't need
a background field in NautilusIndexPanel.
* src/ntl-index-panel.c:
(nautilus_index_panel_set_up_background)
(nautilus_index_panel_finalize):
(nautilus_index_panel_drag_data_received):
(nautilus_index_panel_set_up_info):
Changed the index panel to use NautilusBackground.
* libnautilus/nautilus-background-canvas-group.h:
libnautilus/nautilus-background-canvas-group.c:
(nautilus_background_canvas_group_get_background):
(nautilus_background_canvas_group_set_background):
Moved the code that manages the background object out of the
canvas group code, since we can now attach a background to
any widget.
* libnautilus/gdk-extensions.c:
(nautilus_gdk_color_parse_with_white_default): Changed this helper
to accept NULLs and return the default instead of prohibiting
NULL. This is consistent with the gradient's use of NULL to
represent the default color.
2000-01-11 John Sullivan <sullivan@eazel.com>
* libnautilus/nautilus-gtk-extensions.h:
* libnautilus/nautilus-gtk-extensions.c:
(nautilus_gtk_signal_connect_free_data): New function,
convenience wrapper for gtk_signal_connect_full where
the destroy-function is g_free() and the other extra
values are the defaults.
* src/ntl-window-msgs.c: (nautilus_window_load_content_view_menu):
Use nautilus_gtk_signal_connect_free_data to avoid leaking the menu item's
signal's copy of the iid string.
2000-01-11 John Sullivan <sullivan@eazel.com>
Content view menu now works (can switch between List and Icon views).
* src/ntl-window-msgs.c:
(nautilus_window_load_content_view): Made it return the new
content view, so callers don't need a load_info structure to
determine the new view. Also made it accept NULL for
requesting_view.
(view_menu_switch_views_cb): New function, callback for when
a view is chosen from the list of available content views.
Elliot told me that this requires further work, so I checked
it in with comments for later fixing by Elliot or someone
else who understands the loading process better.
(nautilus_view_load_content_view_menu): Added explicit
parameter for NautilusNavigationInfo for clarity (had been
getting this from deep in window temporary state guts).
Connected view_menu_switch_views_cb to menu items.
* src/ntl-window.c:
(nautilus_window_set_arg): Fixed bug in ARG_CONTENT_VIEW case where
new view was sometimes being added to view hierarchy twice. Then
moved this code into...
(real_nautilus_window_set_content_view): New function, implements
guts of content-view changing so set_arg doesn't have a big block
of code in a switch statement.
(nautilus_window_set_content_view): Moved the gtk_widget_show call
from here to real_nautilus_window_set_content_view so it happens
even if set_arg is called from elsewhere.
(gtk_option_menu_do_resize): Removed this
obsolete function (I removed the callers yesterday but forgot this).
2000-01-11 Darin Adler <darin@eazel.com>
* libnautilus/ntl-view-frame.c: Fixed typos and oversights in
Maciej's check-in. He didn't compile his changes :-(
2000-01-11 Maciej Stachowiak <mjs@eazel.com>
* libnautilus/ntl-view-frame.c, libnautilus/ntl-view-frame.h: Redo
signals the conventional way, to avoid array size mismatches in
the future.
2000-01-10 Maciej Stachowiak <mjs@eazel.com>
* docs/architecture.txt: Some documentation on the nautilus
architecture including a block diagram and some conrol flow
explanations. Needs editing for both style and technical
completeness/accuracy, but it's a start.
* libnautilus/gnome-icon-container.c (handle_icon_button_press):
Reorder code so "context_click" is actually emitted on a button 3
press.
* src/file-manager/fm-main.c,
src/file-manager/fm-directory-view.c,
src/file-manager/fm-directory-view.h: Changed FMDirectoryView to
use a NautilusViewFrame rather than inheriting from one.
* libnautilus/ntl-view-frame.c (nautilus_view_frame_class_init):
Fixed marshall type for "stop_location_change" signal. How could
this ever have worked?
* src/ntl-view.c (nautilus_view_load_client): Once an appropriate
component type is found, do not keep looping.
2000-01-10 John Sullivan <sullivan@eazel.com>
First step at splitting the directory view into separate
icon and list views. List view compiles and runs now,
but is still inaccessible from the UI.
* src/file-manager/fm-directory-view-icons.h:
* src/file-manager/fm-directory-view-icons.c:
* src/file-manager/fm-directory-view-list.h:
* src/file-manager/fm-directory-view-list.c:
New files. These implement two subclasses of FMDirectoryView.
Currently the subclasses are trivial; the only code in the
subclasses other than boilerplate is the one line that sets
the view mode. Later I'll push the rest of the relevant code
down into the subclasses.
* src/file-manager/Makefile.am
Added the four new files to the build.
* src/file-manager/fm-directory-view.c: (init): Removed the
call to fm_directory_view_set_mode since the subclasses are
responsible for this now.
(setup_base_uri): Don't call get_icon_container for non-icon
views, as it asserts if you do; this was broken but since
you couldn't switch to a non-icon view we didn't realize it.
* src/file-manager/fm-main.c: (make_obj): Now calls either
fm_directory_view_icons_get_type() or fm_directory_view_list_get_type()
depending on the goad_id.
* src/file-manager/ntl-file-manager.goad: Replaced entry for
ntl_file_manager with two, one for ntl_file_manager_icon_view
and one for ntl_file_manager_list_view
* src/ntl-uri-map.c: (nautilus_navinfo_new): Now it sets up
the two content views for directories with their new goad ids.
2000-01-10 Maciej Stachowiak <mjs@eazel.com>
* libnautilus/ntl-view-frame.c, libnautilus/ntl-view-frame.c:
Fixed mismatch between declared signal array size and actual
number of signals (this should still be rewritten to follow proper
style).
* libnautilus/ntl-content-view-frame.c,
libnautilus/ntl-content-view-frame.h,
libnautilus/ntl-meta-view-frame.c,
libnautilus/ntl-meta-view-frame.h, libnautilus/ntl-view-frame.c,
libnautilus/ntl-view-frame.h, src/ntl-app.c,
src/ntl-view-bonobo-control.c, src/ntl-view-bonobo-subdoc.c,
src/ntl-view-frame-svr.c, src/ntl-view-nautilus.c,
src/ntl-view-private.h, src/ntl-view.c, src/ntl-view.h,
src/ntl-window-msgs.c, src/ntl-window-msgs.h,
src/ntl-window-state.c, src/ntl-window.c, src/ntl-window.h,
src/file-manager/fm-directory-view.c,
src/file-manager/fm-directory-view.h, src/file-manager/fm-main.c:
Added Eazel copyright to files I've changed non-trivially.
2000-01-10 Darin Adler <darin@eazel.com>
* src/ntl-index-panel.c: (nautilus_index_panel_set_up_label):
Added workaround to problem with basename and gnome-vfs.
2000-01-10 Maciej Stachowiak <mjs@eazel.com>
* libnautilus/ntl-view-frame.c, libnautilus/ntl-view-frame.h,
libnautilus/ntl-content-view-frame.c,
libnautilus/ntl-content-view-frame.h,
libnautilus/ntl-meta-view-frame.c,
libnautilus/ntl-meta-view-frame.h: Renamed from
libnautilus/ntl-view-client.c, libnautilus/ntl-view-client.h,
libnautilus/ntl-content-view-client.c,
libnautilus/ntl-content-view-client.h,
libnautilus/ntl-meta-view-client.c,
libnautilus/ntl-meta-view-client.h.
* libnautilus/Makefile.am, libnautilus/libnautilus.h: reflect this
renaming.
2000-01-10 Darin Adler <darin@eazel.com>
* ntl-window-msgs.c: (nautilus_window_request_progress_change):
(nautilus_window_advance_state):
(nautilus_window_switch_to_new_views):
(nautilus_window_revert_to_old_views):
(nautilus_window_free_load_info):
(nautilus_window_end_location_change):
(nautilus_window_change_location_2):
(nautilus_window_change_location): Got rid of the race condition
in the existing code and cleaned up the state machine a bit. The
new code separates the state of the nautilus window from the state
of the content view, which makes things a bit simpler.
2000-01-10 John Sullivan <sullivan@eazel.com>
Added some of the framework for supporting multiple
content views for the same uri. More to come later.
* src/ntl-types.h: added NautilusViewIdentifier struct
to keep track of iid and human-readable name. Renamed
NautilusNavigationInfo.content_iid to default_content_iid,
and added content_identifiers GSList.
* src/ntl-uri-map.c:
(nautilus_view_identifier_new): New function.
(nautilus_view_identifier_free): New function.
(nautilus_navinfo_new): Create a human-readable-name
for each content iid, and store them together in
content_identifiers list. I included a currently
unworking "List" choice for the directory case, to
test the framework.
(nautilus_navinfo_free): Free the content_identifiers list.
* src/ntl-window-msgs.c:
(nautilus_window_load_content_view_menu): New function,
iterates through the content_identifiers list to fill in
the menu of content view choices. The menu items don't do
anything yet.
(nautilus_window_change_location_internal): Added call to
nautilus_window_load_content_view_menu.
(nautilus_window_change_location_2): Fixed spelling and
grammar in a couple of error messages.
* src/ntl-window.c: (nautilus_window_constructed): Removed
"View as (placeholder)" text in menu; now it has no text
until the actual choices appear. Removed some option-menu-sizing
trickery that didn't work correctly when items were added later.
Now the entire menu is replaced when its contents change.
* src/ntl-window.h: Removed menu_cvtype field; code all uses
just option_cvtype now.
2000-01-10 Darin Adler <darin@eazel.com>
* libnautilus/Makefile.am, libnautilus/nautilus-background.h,
libnautilus/nautilus-background.c,
libnautilus/nautilus-background-canvas-group.h,
libnautilus/nautilus-background-canvas-group.c,
libnautilus/nautilus-lib-self-check-functions.h,
libnautilus/nautilus-lib-self-check-functions.c: Added first cut
at a new class to manage backgrounds that can be colors, color
gradients, or tiled images.
* libnautilus/Makefile.am, libnautilus/nautilus-string.h,
libnautilus/nautilus-string.c: Added functions that manipulate
strings that allow NULLs to reduce NULL checks in code that
treats NULL the same as an empty string.
* libnautilus/gdk_extensions.c: (nautilus_gradient_new):
(nautilus_gradient_is_gradient):
(nautilus_gradient_is_horizontal):
(nautilus_gradient_strip_trailing_direction_if_any):
(nautilus_gradient_get_start_color_spec):
(nautilus_gradient_get_end_color_spec):
(nautilus_gradient_set_edge_color): Changed gradient functions to
allow NULL and treat it the same as an empty string.
* libnautilus/gdk_extensions.h: libnautilus/gdk_extensions.c:
(nautilus_gdk_color_parse_with_default):
(nautilus_gdk_color_parse_with_white_default): Added alternate
version of gdk_color_parse that uses a default color instead of
just returning false. Added self-checks and updated some existing
self checks at the same time.
* src/ntl-index-panel.h, src/ntl-index-panel.c: Wholesale
cleanup and reformatting of NautilusIndexPanel. Fixed a number of
bugs, including storage leaks, and took first step toward using
NautilusBackground class.
* src/ntl-window.c: (nautilus_window_get_requested_uri):
Changed this so it works when window->ni is NULL.
* src/ntl-window.h: Changed index_panel to be a NautilusIndexPanel
now that the index panel interface uses the class instead of using
GtkWidget everywhere.
* src/file-manager/.cvsignore: Added *.la.
* src/file-manager/fm-directory.c: Minor reformatting to match
GNOME code style better.
2000-01-10 16:36:00 +00:00
2000-01-10 John Sullivan <sullivan@eazel.com>
* src/ntl-index-panel.c: (nautilus_index_panel_set_up_label):
Check for NULL filename
2000-01-10 Maciej Stachowiak <mjs@eazel.com>
* src/file-manager/.cvsignore: ignore ntl-file-manager rather than
libntl-file-manager.la
Made file manager view a CORBA server that lives in a separate
executable:
* src/file-manager/fm-main.c: New file which includes main()
function and basic framework to make the file manager an
executable CORBA server.
* src/file-manager/ntl-file-manager.goad: gnorba activation file
for the file manager.
* src/file-manager/Makefile.am: Build ntl-file-manager as an
executable rather than a library. Add fm-main.c to build. Install
ntl-file-manager.goad. Link in appropriate libraries.
* src/ntl-app.c: Remove nautilus_make_object() and other vestiges
of the attempt to be a CORBA server for file manager view objects.
* src/nautilus.gnorba: Removed.
* nautilus-self-check-functions.c: Remove call to test of
functions now in the separate ntl-file-manager executable.
* src/Makefile.am: Don't try to link in file manager. Don't try to
install nautilus.goad.
2000-01-10 Maciej Stachowiak <mjs@eazel.com>
* src/ntl-main.c (main): Added missing CORBA_exception_init() call.
2000-01-09 Maciej Stachowiak <mjs@eazel.com>
* libnautilus/ntl-view-client.c, libnautilus/ntl-view-client.h,
libnautilus/ntl-content-view-client.c,
libnautilus/ntl-content-view-client.h,
libnautilus/ntl-meta-view-client.c,
libnautilus/ntl-meta-view-client.h,: Rename NautilusViewClient to
NautilusViewFrame, NautilusContentViewClient to
NautilusContentViewFrame, and NautilusMetaViewClient to
NautilusMetaViewFrame.
* components/help/hyperbola-nav-tree.c,
components/history/ntl-history-view.c,
components/html/ntl-web-browser.c,
components/websearch/ntl-web-search.c, src/ntl-app.c,
src/file-manager/fm-directory-view.c,
src/file-manager/fm-directory-view.h: Reflect the above renaming.
2000-01-09 Andy Hertzfeld <andy@eazel.com>
* src/ntl-index-panel.c: made dropping a color from the color
picker set the background accordingly. It doesn't save the
meta-data yet, thought
2000-01-09 11:48:16 +00:00
2000-01-09 Maciej Stachowiak <mjs@eazel.com>
* components/websearch/.cvsignore: Added .deps, .libs,
ntl-web-search
2000-01-07 Andy Hertzfeld <andy@eazel.com>
changed the way the index panel gets notified of location changes
removed the index_panel_connect stuff
instead, calls index_panel_set_uri directly from nautilus_window_change_location
* src/ntl-index-panel.c, src/ntl-index-panel.h:
restructured the code that populates the view with the info,
added logic to use as large a font as possible for the title
fixed bug involving the path ending with a slash.
* src/ntl-window-msgs.c:
added explicit call to index_panel_set_uri as mentioned above
* src/ntl-window.c
removed call to index_panel_connect as mentioned above
2000-01-07 John Sullivan <sullivan@eazel.com>
Added and deployed utility routine for presenting a
window (in any current state) to user.
* libnautilus/nautilus-gtk-extensions.h:
* libnautilus/nautilus-gtk-extensions.c: New files
(nautilus_gtk_window_present): New function, presents
a window to user (opens it, brings it to front w/focus)
regardless of whether it was showing, buried, hidden, or
minimized.
* libnautilus/Makefile.am: added these two new files. Also
changed ".c" to ".h" for two self-check files in the HEADERS
list (apparent typo).
* src/nautilus-bookmarks-menu.c: (edit_bookmarks_cb):
Replaced call to nautilus_bookmarks_window_present with
call to nautilus_gtk_window_present.
* src/nautilus-bookmarks-window.c:
* src/nautilus-bookmarks-window.h:
(nautilus_bookmarks_window_present): Deleted this function.
* src/nautilus-bookmarks-window.c:
(create-bookmarks-window): Now calls nautilus_bookmarks_
window_restore_geometry just once here, instead of every
time window was shown.
* src/ntl-window.c: (nautilus_about_window_cb):
Now it keeps around a single About window, instead of
creating a new one each time (you could litter the screen
with About windows before). Also removed some obsolete
gtk_widget_set_sensitive calls.
2000-01-07 John Sullivan <sullivan@eazel.com>
Bookmarks window position is now saved & restored within
a session and across sessions. Some of this work can be
turned into general-purpose utilities but I didn't do
that yet (I will when we have a second need for it)
* src/nautilus-bookmarklist.c:
* src/nautilus-bookmarklist.h:
(nautilus_bookmarklist_set_window_geometry):
(nautilus_bookmarklist_get_window_geometry): New functions,
take/return a string representing the window position.
* src/nautilus-bookmarklist.c:
(nautilus_bookmarklist_load_file):
(nautilus_bookmarklist_save_file): read/write xml node for
window geometry in addition to bookmarks. Also cleaned up
a couple of leaked results from xmlGetProp and reformatted.
(set_window_geometry_internal): New utility function.
* src/nautilus-bookmarks-menu.c: (edit_bookmarks_cb): Moved
window-displaying logic out of this routine and into new
routine nautilus_bookmarks_window_present(), which is now
called here.
* src/nautilus-boomarks-menu.c:
* src/nautilus-boomarks-menu.h:
(nautilus_bookmarks_menu_exiting): New function, handles telling
bookmarks window to save itself when application exits.
* src/ntl-app.c: (nautilus_app_exiting): Now calls
nautilus_bookmarks_menu_exiting.
* src/nautilus.h: Now #includes "nautilus-bookmarks-menu.h"
* src/nautilus-bookmarks-window.h:
* src/nautilus-bookmarks-window.c:
(nautilus_bookmarks_window_present): New function, handles
presenting the bookmarks window on screen regardless of current state.
(nautilus_bookmarks_window_save_geometry): New function, reads window
position & size and passes them along to
nautilus_bookmarklist_set_window_geometry for safe-keeping.
* src/nautilus-bookmarks-window.c:
(nautilus_bookmarks_window_restore_geometry): New function, gets
window geometry from bookmarklist and sets window size & position
from it (after adjusting with some sanity checks)
(create_bookmarks_window): Replaced set_default_size call with
nautilus_bookmarks_window_restore_geometry call.
2000-01-07 Elliot Lee <sopwith@redhat.com>
* src/ntl-window.c, src/ntl-index-panel.c: Fix warnings.
2000-01-07 Andy Hertzfeld <andy@eazel.com>
* src/ntl-index-panel.h, src/ntl-index-panel.c: new files for index panel class
Initial bare-bones implementation of index panel still using notebook object instead of custom tabs
* src/ntl-window.h, src/ntl-window.c
just use box instead of pane for nautilus window content,
index_panel now responsible for the meta-views
allocate and install index_panel instead of meta_notebook
connect_signals calls index_panel so it can connect, too
added myself as an author
* src/Makefile.am
added index_panel class
2000-01-06 Darin Adler <darin@eazel.com>
* libnautilus/Makefile.am,
libnautilus/nautilus-lib-self-check-functions.c,
libnautilus/nautilus-lib-self-check-functions.h,
libnautilus/nautilus-self-checks.c,
libnautilus/nautilus-self-checks.h, src/Makefile.am,
src/nautilus-self-check-functions.c,
src/nautilus-self-check-functions.h, src/nautilus-self-checks.c,
src/nautilus-self-checks.h, src/ntl-main.c (main),
src/file-manager/fm-directory.c,
src/file-manager/fm-vfs-directory.c: Moved self-check framework
into libnautilus. Added functions so each check will report if it
fails instead of just aborting.
* src/gdk-extensions.c, src/gdk-extensions.h
(nautilus_gradient_new, nautilus_gradient_is_gradient,
nautilus_gradient_get_start_color_spec,
nautilus_gradient_get_end_color_spec,
nautilus_gradient_is_horizontal,
nautilus_gradient_set_left_color_spec,
nautilus_gradient_set_top_color_spec,
nautilus_gradient_set_right_color_spec,
nautilus_gradient_set_bottom_color_spec): Added new functions to
manage a string that specifies a color or gradient, and added
tests for the new functions.
2000-01-06 John Sullivan <sullivan@eazel.com>
* src/ntl-app.h: src/ntl-app.c: (nautilus_app_exiting):
New function for doing app-wide cleanup. Moved call to
nautilus_prefs_save in here.
* src/ntl-app.c: (nautilus_app_destroy_window): Former
home of call to nautilus_prefs_save.
* src/ntl-main.c: (main): After event loop concludes,
call nautilus_app_exiting.
2000-01-06 Elliot Lee <sopwith@redhat.com>
* libnautilus/gnome-icon-container.c: Relayout when size changes.
2000-01-06 Andy Hertzfeld <andy@eazel.com>
* ntl-window.c: made location bar draggable to be consistent with the others by removing DOCK_LOCKED
flag
2000-01-06 15:35:22 +00:00
2000-01-06 Elliot Lee <sopwith@redhat.com>
* libnautilus/gnome-icon-container.c: Eliminate gratuitous scroll bars.
2000-01-06 15:35:22 +00:00
* src/ntl-window-msgs.c, components/help/hyperbola-filefmt.c, components/html/gnome-dialogs.c: Bug fixes.
2000-01-06 15:23:17 +00:00
2000-01-06 John Sullivan <sullivan@eazel.com>
* src/ntl-prefs.c: added NULLs to array initializers to
eliminate compiler warnings.
2000-01-06 Elliot Lee <sopwith@redhat.com>
* src/ntl-prefs.c, src/ntl-uri-map.c: Implement preferences for
which meta-views to always load with a page. Loading doesn't seem to quite work.
* src/ntl-window.c, src/ntl-view.c: Try to fix a crash that
happens when going to a new page, and a meta view is being
destroyed in the process. Still crashes.
2000-01-05 Maciej Stachowiak <mjs@eazel.com>
* src/ntl-uri-map.c (nautilus_navinfo_free): Fix warning.
2000-01-05 Elliot Lee <sopwith@redhat.com>
* src/ntl-types.h, src/ntl-uri-map.[ch], src/ntl-window-msgs.c, src/ntl-window.[ch]:
Add support for the location change state machine and related notifications,
to allow much better error handling.
* src/ntl-view.[ch]: Catch client failures, also allow for active sensing of client death.
* src/file-manager/fm-directory-view.c: Send progress notifications.
* components/html/ntl-web-browser.c: Send progress
notifications. Try to fix crashes caused by ending an error stream
twice.
* src/file-manager/fm-icon-cache.c: Update for gdk-pixbuf changes.
2000-01-05 John Sullivan <sullivan@eazel.com>
* src/nautilus-bookmarks-window.c: (create_bookmarks_window):
Remove horizontal scroll bar from list via set_policy.
2000-01-05 John Sullivan <sullivan@eazel.com>
* src/nautilus-bookmarks-menu.c: (nautilus_bookmarks_menu_fill):
Stopped using GNOMEUIINFO_ITEM_DATA macro, because it doesn't work
right (on some machines) when there's no pixmap for the item.
2000-01-04 John Sullivan <sullivan@eazel.com>
* src/nautilus-bookmarks-menu.c: comment changes only
* src/nautilus-bookmarks-window.c:
(create_bookmarks_window): added padding to "Remove" button
so it isn't so scrawny.
(on_remove_button_clicked): Removed item from clist explicitly
instead of relying on notification that bookmark list changed;
this correctly moves the selection to the next item instead of
jumping it back to the top of the list.
2000-01-04 Darin Adler <darin@eazel.com>
A couple of quick fixes to make "make check" work again.
* src/file-manager/fm-directory.c (fm_directory_initialize):
src/file-manager/fm-vfs-directory.c (fm_vfs_directory_initialize):
Use g_new0 instead of g_new for details structure to better
mimic what gtk_object_new does.
* src/file-manager/fm-directory.c (fm_directory_get):
Added an assert to check that the hash table key is set up
correctly. This was failing when John did a "make check".
* src/file-manager/fm-vfs-directory.c (fm_vfs_directory_new):
Set up the hash table key when creating the object. This
was causing a failure in "make check".
2000-01-04 John Sullivan <sullivan@eazel.com>
* src/nautilus-bookmarks-window.c (create_bookmarks_window):
Replaced hardwired numbers with constants; specified a minimum
size separate from default size and changed parameter to
gtk_window_set_policy to prevent shrinking below minimum size.
2000-01-04 John Sullivan <sullivan@eazel.com>
After talking with Sopwith and Darin, removed
my changes from earlier today. The current framework
handles bogus URIs better than I thought, though still
with some known problems. I can't implement the bookmarks
part until the problems are fixed. And the new functions
don't seem to be required in any case.
* libnautilus/nautilus-uri-utilities.c: removed file
* libnautilus/nautilus-uri-utilities.h: removed file
* libnautilus/Makefile.am: removed these two files
from the build, and removed GnomeVFS
* src/ntl-window.c: removed #include for nautilus-uri-utilitie.h.
Sopwith had removed the call from (nautilus_window_goto_uri_cb)
earlier (without a ChangeLog entry).
2000-01-04 Darin Adler <darin@eazel.com>
* src/Makefile.am, src/check-nautilus,
src/nautilus-self-check-functions.h, src/nautilus-self-checks.c,
src/nautilus-self-checks.h, src/ntl-main.c (main): Added self
checks to nautilus. The checks are invoked by "make check"
(actually need to do "make install check" if you changed
libnautilus) or by invoking the nautilus executable with "--check".
Later, nautilus-self-checks.h may include various helpful
functions for use by the self-checking code.
* src/file-manager/Makefile.am, src/file-manager/fm-directory.c,
src/file-manager/fm-directory.h,
src/file-manager/fm-directory-protected.h,
src/file-manager/fm-vfs-directory.c,
src/file-manager/fm-vfs-directory.h: Started work on an abstract
FMDirectory class that provides a model for what's viewed by the
file manager. Also began work on the FMVFSDirectory concrete child
class that implements this on top of VFS. It's not hooked up yet,
and there's a lot that needs to be done before it's ready to use.
* libnautilus/gdk-extensions.c, libnautilus/gdk-extensions.h:
Renamed functions to use nautilus_ prefix instead of gdk_
prefix. Added a tiny bit of self-check code.
* libnautilus/nautilus-gtk-macros.h: Added some macros (that will
no doubt be controversial) to do some basic GTK object
boilerplate.
2000-01-04 John Sullivan <sullivan@eazel.com>
Made location-entering field handle bogus URIs better
(next: bookmarks)
* libnautilus/nautilus-uri-utilities.c: new file
* libnautilus/nautilus-uri-utilities.h: new file
At this point there's just one uri utility function,
nautilus_path_known_not_to_exist(), which is a quick
check for a bogus URI. (It's not guaranteed to return
TRUE for all bad URIs, just the ones it can tell quickly
are bogus).
* libnautilus/Makefile.am: added these two new files
to the build, and linked with GnomeVFS (needed for new
function)
* src/ntl-window.c: (nautilus_window_goto_uri_cb):
If typed path can quickly be rejected, puts an error
message in the status bar and doesn't try to go there.
* components/websearch/.cvsignore: added Makefile
2000-01-03 Maciej Stachowiak <mjs@eazel.com>
* idl/nautilus.idl: Added stop_location_change method to NautilusView interface.
* ntl-view-client.c, ntl-view-client.h (stop_location_change): New
signal, triggered on receipt of stop_location_change request via
CORBA.
* ntl-view.c, ntl-view.h, ntl-view-private.h, ntl-view-nautilus.c,
ntl-view-bonobo-control.c, ntl-view-bonobo-subdoc.c
(nautilus_view_stop_location_change): Added this function; also
added implementation to nautilus view type function table and
NULL'd out for now for Bonobo control and subdoc view types (need
to find out if loading is synchronous or asynchronous for those,
and if there is a way to abort).
* ntl-window.c: Stop loading for all views when Stop button is
pressed.
* ntl-window-msgs.c: Enable stop button when we start loading;
enable Stop button when
* src/file-manager/fm-directory-view.c: Call
request_progress_change() when loading is done or an error is
reached; implement handler for stop_location_change signal.
Fix warnings. 2000-01-03 Maciej Stachowiak <mjs@eazel.com> * src/ntl-prefs.c: Fix warnings. * src/ntl-view.c, src/ntl-view.h, src/ntl-view-frame-svr.c (nautilus_view_notify_location_change, nautilus_view_notify_selection_change, nautilus_view_load_state, nautilus_view_save_state, nautilus_view_show_properties): Made these functions public and removed the corresponding signals; these are operations you do to the NautilusView, not something it informs other parts of the program of. (request_location_change, request_selection_change, request_status_change, request_progress_change): New signals. These allow NautilusView to have less dependence on NautilusWindow. (nautilus_view_signals): Moved signal number table from view to this static variable. (nautilus_view_request_location_change, nautilus_view_request_selection_change, nautilus_view_request_status_change, nautilus_view_request_progress_change): Move to ntl-view.c and make them emit the proper signals in lieu of hardcoded handling. * src/ntl-window.c, src/ntl-window.h src/ntl-window-msgs.c, src/ntl-window-msgs.h, src/ntl-window-state.c (request_location_change, request_selection_change, request_status_change, request_progress_change): Removed these signals; they are operations you do on a NautilusWindow, not something it notifies you of, and any usefulness for inheritance purposes is purely speculative right now. (nautilus_window_connect_view, nautilus_window_disconnect_view): Use these new helper functions to connect callbacks to NautilusView's signals instead of expecting them to just get called. (nautilus_view_request_location_change, nautilus_view_request_selection_change, nautilus_view_request_status_change, nautilus_view_request_progress_change): Execute bodies of real_ versions instead of emitting singals. (nautilus_view_real_request_location_change, nautilus_view_real_request_selection_change, nautilus_view_real_request_status_change, nautilus_view_real_request_progress_change): Removed these. Finally, always call nautilus_winodow_set_content_view or nautilus_window_add_meta_view before calling nautilus_view_load_client to make sure no signals are lost.
2000-01-04 03:06:28 +00:00
2000-01-03 Maciej Stachowiak <mjs@eazel.com>
* src/ntl-prefs.c: Fix warnings.
* src/ntl-view.c, src/ntl-view.h, src/ntl-view-frame-svr.c
(nautilus_view_notify_location_change,
nautilus_view_notify_selection_change, nautilus_view_load_state,
nautilus_view_save_state, nautilus_view_show_properties): Made
these functions public and removed the corresponding signals;
these are operations you do to the NautilusView, not something it
informs other parts of the program of.
(request_location_change, request_selection_change,
request_status_change, request_progress_change): New
signals. These allow NautilusView to have less dependence on
NautilusWindow.
(nautilus_view_signals): Moved signal number table from view to
this static variable.
(nautilus_view_request_location_change,
nautilus_view_request_selection_change,
nautilus_view_request_status_change,
nautilus_view_request_progress_change): Move to ntl-view.c and
make them emit the proper signals in lieu of hardcoded handling.
* src/ntl-window.c, src/ntl-window.h src/ntl-window-msgs.c,
src/ntl-window-msgs.h, src/ntl-window-state.c
(request_location_change, request_selection_change,
request_status_change, request_progress_change): Removed these
signals; they are operations you do on a NautilusWindow, not
something it notifies you of, and any usefulness for inheritance
purposes is purely speculative right now.
(nautilus_window_connect_view, nautilus_window_disconnect_view):
Use these new helper functions to connect callbacks to
NautilusView's signals instead of expecting them to just get
called.
(nautilus_view_request_location_change,
nautilus_view_request_selection_change,
nautilus_view_request_status_change,
nautilus_view_request_progress_change): Execute bodies of real_
versions instead of emitting singals.
(nautilus_view_real_request_location_change,
nautilus_view_real_request_selection_change,
nautilus_view_real_request_status_change,
nautilus_view_real_request_progress_change): Removed these.
Finally, always call nautilus_winodow_set_content_view or
nautilus_window_add_meta_view before calling
nautilus_view_load_client to make sure no signals are lost.
2000-01-03 Elliot Lee <sopwith@redhat.com>
* components/websearch, configure.in: The ten minute version of kwebsearch.
* components/html/ntl-web-browser.c: Handle forms (POST is untested and probably buggy).
* src/ntl-uri-map.c: Check result of file_info retrieval. Load web search by default.
* src/ntl-prefs.[ch]: First (lame) attempt at implementing application preferences.
* src/ntl-app.c: Load prefs at startup
2000-01-03 John Sullivan <sullivan@eazel.com>
Added underline-accelerators to Add Bookmark and
Edit Bookmarks in Bookmarks menu. This was much
more difficult than I expected.
* src/nautilus-bookmarks-menu.c:
(init): Removed all the guts of this function.
(nautilus_bookmarks_menu_new): Now calls
nautilus_bookmarks_menu_fill() on freshly-created menu.
(nautilus_bookmarks_menu_fill): New function, takes over
the chore of initially populating the Bookmarks menu.
Uses GnomeUIInfo structs to set up Add Bookmarks and
Edit Bookmarks so they'll have underline-accelerators.
Also they now have tooltip strings (and I added a call
to gnome_app_install_menu_hints() to make the tooltips work).
2000-01-03 John Sullivan <sullivan@eazel.com>
Fixed memory leaks in bookmarks stuff
* src/nautilus-bookmarklist.c: (nautilus_bookmarklist_delete_item_at):
Destroy the bookmark when removing it from list.
* src/nautilus-bookmarks-menu.c:
(nautilus_bookmarks_menu_repopulate):
Store an index rather than a bookmark in the menu item, since the
item will be destroyed if the menu is reordered.
(bookmark_activated_cb): Find bookmark from the index stored in item.
2000-01-03 John Sullivan <sullivan@eazel.com>
Started new file for file-related utilities in Nautilus.
* libnautilus/nautilus-file-utilities.h : new file
* libnautilus/nautilus-file-utilities.c : new file
* libnautilus/Makefile.am : added these two new files to the build.
* src/nautilus_bookmarklist.c:
(nautilus_bookmarklist_get_file_path): Deployed
nautilus_make_path() and nautilus_user_directory()
2000-01-03 Darin Adler <darin@eazel.com>
* configure.in: Added "-Wall -Wno-unused" to list of warnings.
It seems to me that at one point we got these from the gnome
default warnings, but this seems to have stopped. There's no
harm in repeating them in here and it fixes the problem for
now, but I'd like to know what happened.
* components/html/.cvsignore: Added some generated files.
* components/html/gnome-dialogs.c: (glibwww_progress):
Replaced an incorrect "%l" in a printf format string with
the correct "%ld".
* libnautilus/.cvsignore: Added some generated files.
2000-01-03 John Sullivan <sullivan@eazel.com>
* src/nautilus_bookmarklist.c:
(nautilus_bookmarklist_save_file): Took out unused local
variables. My compiler didn't notice these because -Wall
isn't in our compile flags. Darin is fixing the compile flags.
2000-01-03 Elliot Lee <sopwith@redhat.com>
* All files: Update copyright notices.
1999-12-30 John Sullivan <sullivan@eazel.com>
* src/nautilus_bookmarklist.c: (nautilus_bookmarklist_get_file_path):
Create directory that contains bookmarks file if it's not already
there. Saving bookmarks would have failed (silently) for anyone
who didn't already have a ~/.gnomad directory without this change.
1999-12-30 John Sullivan <sullivan@eazel.com>
Made NautilusBookmark use gchar * instead of GString
since it wasn't using any special GString features.
* src/nautilus-bookmark.h: changed definition in struct
* str/nautilus-bookmark.c:
(nautilus_bookmark_destroy): changed g_string_free to g_free
(init): eliminated g_string_new
(nautilus_bookmark_get_name): replaced bookmark->uri->name
with bookmark->name
(nautilus_bookmark_get-uri): replaced bookmark->uri->str
with bookmark->uri
(nautilus_bookmark_new): changed initializers from
GString style to gchar * style
Save/restore bookmarks across sessions with XML file.
* src/nautilus_bookmarklist.c:
(append_bookmark_node): new foreach static function
(destroy_bookmark): new foreach static function
(nautilus_bookmarklist_get_file_path): new static function
(nautilus_bookmarklist_load_file): new static function
(nautilus_bookmarklist_save_file): new static function
(init): renamed to nautilus_bookmark_init
(class_init): renamed to nautilus_bookmark_class_init
(nautilus_bookmarklist_contents_changed): now calls
nautilus_bookmarklist_save_file
(nautilus_bookmarklist_init): now calls
nautilus_bookmarklist_load_file
1999-12-30 John Sullivan <sullivan@eazel.com>
Linked in GNOME-XML library, since I'll need it for bookmarks.
* configure.in: defined XML-related macros (copied from gconf)
* src/Makefile.am: included $(XML_CFLAGS) and $(XML_LIBS)
1999-12-30 John Sullivan <sullivan@eazel.com>
The bookmark-editing window is now functional, though simple.
It allows editing names & uris, reordering bookmarks via
dragging in the list, and removing bookmarks. Coming next:
bookmarks persisting across sessions.
* src/nautilus-bookmarks-window.h: New file.
* src/nautilus-bookmarks-window.c: New file.
* src/Makefile.am: added nautilus-bookmarks-window.[ch]
* src/nautilus-bookmarklist.h, nautilus-bookmarklist.c:
(nautilus_bookmarklist_delete_item_at): New function
(nautilus_bookmarklist_insert_item): New function
* src/nautilus-bookmarks-menu.c: (init): Removed
insensitization of Edit Bookmarks item.
Added parameter names to prototypes where they were missing
* src/nautilus-bookmark.h
* src/nautilus-bookmarklist.h
* src/nautilus-bookmarks-menu.h
Fixed bug where activating bookmarks failed in any but the
first window
* src/nautilus-bookmarks-menu.c
(bookmark_activated_cb):
(nautilus_bookmarks_menu_repopulate):
Changed bookmark menu items to keep a pointer to their
menu, rather than the menu's window, because sometimes
the menu's window isn't set when the menu item is created.
1999-12-29 John Sullivan <sullivan@eazel.com>
* src/nautilus-bookmarklist.c:
(nautilus_bookmarklist_contains):
changed two g_return_if_fail to g_return_val_if_fail. Eek! I
accidentally checked this in yesterday without compiling. I
should be tarred and feathered.
(nautilus_bookmarklist_append): Now calls new nautilus_bookmark_copy
* src/nautilus-bookmark.c:
(nautilus_bookmark_copy): New method
* src/nautilus-bookmark.h:
(nautilus_bookmark_copy): New method
1999-12-28 John Sullivan <sullivan@eazel.com>
* src/nautilus-bookmark.c:
* src/nautilus-bookmarklist.c:
* src/nautilus-bookmarks-menu.c:
Removed unnecessary g_return_if_fail (obj != NULL) calls
since the g_return_if_fail (NAUTILUS_IS_WHATEVER (obj)) call
also handles the NULL case. Also added some more calls of
the latter type.
1999-12-28 John Sullivan <sullivan@eazel.com>
* src/nautilus-bookmark.c, src/nautilus-bookmark.h:
(nautilus_bookmark_compare_with):
new function, compares two bookmarks for equivalence, used by:
* src/nautilus-bookmarklist.c, src/nautilus-bookmarklist.h:
(nautilus_bookmarklist_contains):
new function, checks whether a given bookmark is already in the
list, used by:
* src/nautilus-bookmarks-menu.c, src/nautilus-bookmarks-menu.h:
(add_bookmark_cb): now silently refuses to add another bookmark
for the current location if there's one already in the list.
(init): now uses connect_signal_while_alive to avoid nastiness
when trying to add a bookmark after one or more windows were closed.
* src/ntl-window.c: (file_menu_new_window_cb): Now calls
nautilus_app_create_window() instead of creating the new window
in line, so that the window count gets properly updated and closing
windows works correctly.
1999-12-28 John Sullivan <sullivan@eazel.com>
* src/ntl-view.c: (nautilus_view_load_client):
Undid the previous change. It turned out I
needed to rebuild the latest ORBit and then
the latest gnome-libs. I had built them in
the wrong order before.
1999-12-28 18:49:05 +00:00
1999-12-28 John Sullivan <sullivan@eazel.com>
* src/ntl-view.c: (nautilus_view_load_client): cast
a const CORBA_char * to a CORBA_char * in call to
GNOME_Unknown_query_interface to fix the build.
Darin thinks this is a mistake in the API and is
investigating fixing the API.
1999-12-22 Elliot Lee <sopwith@redhat.com>
* src/ntl-uri-map.[ch]: Add initialization function. Implement scheme mapping.
* components/history/ntl-history-view.c: Testbed for UIHandler usage.
* src/ntl-*view*.c: Better error checking, support UIHandler usage.
* src/ntl-window-msgs.c: Better error checking.
* src/ntl-window.c: Better error checking, plus move menu creation so that UIHandler usage is easier.
1999-12-21 Elliot Lee <sopwith@redhat.com>
* idl/nautilus.idl, libnautilus/ntl-view-client.[ch], src/ntl-window*.[ch], src/ntl-view-frame-svr.c:
Add request_progress_change notification
* src/ntl-view-*: Fix/finish various mjs changes: Do the component type abstraction properly,
lose ntl-view-frame-svr.h, add ntl-view-private.h, add various component type implementations.
* src/ntl-view-frame-svr.h: Add 'extern' so everyone doesn't get their
own vepv variable.
1999-12-20 Maciej Stachowiak <mjs@eazel.com>
* src/ntl-view.h: Remove request_* calls from public API (they are
just an implementation detail of the fact that NautilusView
implements a Nautilus:ViewFrame CORBA server - the nautilus app
should not need to call these).
* src/ntl-view.c: Split all the three way conditional stuff out so
there is a separate function for each branch of the condition. Not
a big win yet, but will provide opportunities for more
refactoring.
* src/ntl-view-frame-svr.c, ntl-view-frame-svr.h: Move
implementation of Nautilus:ViewFrame CORBA server here as much as
possible.
* src/ntl-view.c: Remove it from here.
* src/nautilus.h: #include ntl-view-frame-svr.h
* src/Makefile.am: add ntl-view-frame-svr.[ch] to build.
* src/ntl-window.c: Add myself to About box (pout).
1999-12-21 03:59:29 +00:00
* components/html/ntl-web-browser.c: Fix warnings.
1999-12-20 Elliot Lee <sopwith@redhat.com>
* configure.in, components/Makefile.am: Add HTML component to build.
* components/help/hyperbola-main.c, components/history/ntl-history-view.c: Make process die when
all objects have been destroyed.
* components/history/ntl-history-view.c: Bug fixes.
* components/html/*.[ch]: Copy glibwww over, write new NautilusViewClient for HTML browsing.
* src/ntl-uri-map.c: Cleanup, and use ntl_web_browser as default HTML display engine.
* src/ntl-view.c: Try to handle Bonobo views for data display.
1999-12-20 John Sullivan <sullivan@eazel.com>
* src/nautilus-bookmark.h,c: new files
* src/nautilus-bookmarklist.h,c: new files
* src/nautilus-bookmarks-menu.h,c: new files
* src/Makefile.am: added these six new files to nautilus_SOURCES
* src/ntl-window.c: now #includes nautilus-bookmarks-menu.h
(bookmarks_menu_info[]): removed all items except GNOMEUIINFO_END;
subtree is added dynamically later.
(nautilus-window-constructed): insert bookmarks menu
(nautilus-window-constructed): add padding to status bar so text
isn't jammed against frame.
The bookmark menu is now limping along. The Add Bookmark item works,
and the items that get added do the right thing. Edit Bookmarks is
still insensitive, so there's no way to remove items. Except by
quitting, because they aren't yet being saved/restored across sessions.
1999-12-20 Havoc Pennington <hp@redhat.com>
* src/file-manager/fm-icon-cache.c: Add inline RGB data for
default icon.
(fm_icon_cache_load_icon): only
ref the pixbuf if it exists
(fm_icon_cache_new): add a new fallback special icon set
(fm_icon_cache_load_icon): load fallback if the icon name is ""
1999-12-20 Havoc Pennington <hp@redhat.com>
* libnautilus/gnome-icon-container.c (set_kbd_current): return if
the icon being set is NULL. This may be fixing a symptom rather
than a problem.
1999-12-20 Elliot Lee <sopwith@redhat.com>
* src/ntl-*.[ch]: Support multiple view types (Nautilus/View, GNOME/Control, GNOME/Embeddable)
* src/ntl-window.[ch]: Add nautilus_window_get_uih()
* idl/*.idl: Reindent.
1999-12-19 Havoc Pennington <hp@pobox.com>
* src/file-manager/desktop-window.c (desktop_window_realize): turn
on window decorations for debugging
(desktop_window_init): debug comment-out the no-resize policy
* src/file-manager/desktop-layout.c (desktop_layout_arrange):
fool with layout routines
* src/file-manager/desktop-canvas.c
(desktop_canvas_size_allocate): debugging border to detect layout screwups
* src/file-manager/desktop-item.c (icon_realize): set the canvas
item, oops.
1999-12-19 Havoc Pennington <hp@pobox.com>
* src/file-manager/desktop-layout.c: don't do an arrangement
on every change
* src/file-manager/desktop-canvas.c
(desktop_canvas_load_desktop_icons): connect to finished_load and
arrange the icons when we get it. This is a temporary hack,
because the DesktopLayout engine isn't progressive yet.
* src/file-manager/fm-directory-list.c
(fm_directory_list_class_init): add a finished_load signal
* src/file-manager/desktop-window.c (desktop_window_init): for
now, don't fill the whole screen so we can see gdb.
* src/file-manager/desktop-item.c: Move user data accessors into
the .c file, these are private.
1999-12-17 Havoc Pennington <hp@redhat.com>
1999-12-19 06:47:22 +00:00
* src/file-manager/desktop-item.h: New module, for items
on the desktop
* src/file-manager/fm-directory-view.c: Change to use
get_current_icon_cache() (it wasn't ever freeing the icon cache anyway)
* src/file-manager/fm-icon-cache.c (fm_get_current_icon_cache):
function to get a global icon cache, we will share this throughout
the program.
1999-12-19 Havoc Pennington <hp@pobox.com>
* src/file-manager/desktop-canvas.c
(desktop_canvas_load_desktop_icons): new function, loads icons
from a given directory - don't get too excited, it doesn't yet
_display_ any icons!
* src/file-manager/desktop-canvas.h: Add directory list field.
* src/file-manager/Makefile.am (gnome_desktop_SOURCES): Add
fm-directory-list.[hc]
(libntl_file_manager_la_SOURCES): add fm_directory_list.[hc]
* src/file-manager/fm-directory-list.h, fm-directory-list.c:
New files, the non-GUI portion of a directory listing. Handles
loading the dir listing and the icons.
1999-12-17 Maciej Stachowiak <mjs@eazel.com>
* src/ntl-window.c, src/ntl-window-msgs.c: Added up, reload, home,
stop toolbar buttons. Stop is not implemented yet. Up needs more
thought with respect to various protocols.
* src/ntl-window.c, src/ntl-window.h: Added calls to
allow/disallow some of the toolbar operations.
1999-12-19 06:47:22 +00:00
1999-12-17 Havoc Pennington <hp@redhat.com>
* src/file-manager/fm-directory-view.c: Change to use
get_current_icon_cache() (it wasn't ever freeing the icon cache anyway)
* src/file-manager/fm-icon-cache.c (fm_get_current_icon_cache):
function to get a global icon cache, we will share this throughout
the program.
1999-12-17 Havoc Pennington <hp@redhat.com>
* src/ntl-window.c (nautilus_window_realize): set the mini icon.
(nautilus_window_class_init): init parent_class and install
realize method
* src/ntl-miniicon.c: new files, to set mini icon
1999-12-16 Elliot Lee <sopwith@redhat.com>
* libnautilus/{gdk-extensions.c,gnome-icon-container.c}: Fix warnings
* libnautilus/gnome-icon-container.c: Try (unsuccessfully) to get
proper icon reflow by calling icon_grid_resize() instead of
icon_grid_set_visible_width(), in size_allocate().
* src/*.*: Add ntl-app.[ch].
* src/file-manager/desktop-*.c: Fix warnings.
* src/file-manager/fm-directory-view.c: Remove incorrect warning,
allow turning off use of icon_layout altogether.
1999-12-16 John Sullivan <sullivan@eazel.com>
* src/ntl-window.c:
* src/ntl-main.c:
* src/file-manager/fm-directory-view.c:
Changed evil // comments to /* */. Sorry about that!
* src/ntl-window.c: added insensitive rudimentary Bookmark menu
1999-12-16 Havoc Pennington <hp@redhat.com>
* src/ntl-window-state.c (nautilus_window_save_state): lookup
signum before it's first used.
* src/file-manager/desktop-layout.c: new layout module, not yet
done
* src/file-manager/desktop-canvas.c (desktop_canvas_init): Create
the right-click menu.
* src/file-manager/desktop-menu.c (desktop_menu_new): New module
to stick the right-click menu code in
1999-12-16 23:10:22 +00:00
1999-12-16 Maciej Stachowiak <mjs@eazel.com>
* src/ntl-window.c: Put meta-views on the right.
* src/ntl-window.c, src/ntl-main.c, src/ntl-window.h,
src/ntl-window-msgs.c, src/ntl-window-state.c: Enabled multiple
main windows and new window menu entry. In the process replaced
url with uri where appropriate and added
nautilus_window_get_requested_uri accessor.
1999-12-16 23:10:22 +00:00
1999-12-16 Darin Adler <darin@eazel.com>
* libnautilus/.cvsignore: Ignore all *.lo instead of listing each.
* libnautilus/Makefile.am: Added gdk-extensions.c and $(WERROR).
* libnautilus/gdk-extensions.[ch]: Added functions for filling with a
gradient. Currently they are named gdk_fill_rectangle_with_gradient
and gdk_interpolate_color, but perhaps the gdk_ prefix should be
replaced with another one. These functions are not yet tested, but they
compile and I want to get them in here before I leave for vacation.
* src/ntl-uri-map.c: (nautilus_navinfo_new): Some null checks in
the "click on an item" hack. This was a halfhearted attempt to get
the program to not segfault when you open icons.
* src/ntl-window-msgs.c: (nautilus_window_load_content_view):
Some g_return_if_fail in here. I'll add a ton more at some point.
These were part of the halfhearted attempt to get the program to
not segfault when you open icons.
* src/file-manager/.cvsignore: Igore all *.lo instead of listing each.
1999-12-16 Elliot Lee <sopwith@redhat.com>
* components/history/ntl-history-view.c: Now works.
* src/ntl-uri-map.c: Duplicate the URI being requested, since we
don't know what the lifetime of the original value will be.
* src/ntl-window.c: Use the paned instead of hbox, use create_menus_with_data instead.
* src/file-manager: Misc warning fixes.
* src/gtkscrollframe.c: Try to get rid of scrollbar chopping.
1999-12-16 John Sullivan <sullivan@eazel.com>
* src/ntl-window.c (file_menu_new_window_cb):
New, currently empty callback.
* src/ntl-window.c (file_menu_info[]):
Added New Window item.
* src/ntl-window.c (edit_menu_info[]):
Added standard menu items, all unimplemented as of now.
* src/ntl-window.c (help_menu_info[]):
Added About item, unimplemented as of now.
* src/ntl-window.c (main_menu[]):
Now includes edit and help menus.
* src/ntl-window.c (nautilus_window_constructed):
Changed the way the toolbar is created, to fix bug
where Back failed because data parameter was NULL.
Also desensitized all the new unimplemented menu items.
1999-12-16 21:08:40 +00:00
1999-12-16 Maciej Stachowiak <mjs@eazel.com>
* src/file-manager/gnome-desktop.c (main): Quiet some warnings.
1999-12-16 Havoc Pennington <hp@redhat.com>
* src/file-manager/gnome-desktop.c (main): warning fixes
* src/file-manager/desktop-canvas.c
(desktop_canvas_update_background): start actually honoring
background settings.
* src/file-manager/fm-icon-cache.c: add copyright and Emacs magic.
* src/file-manager/fm-icon-cache.h (fm_icon_cache_get_icon): Run
egtk-format-protos on these prototypes, add copyright and Emacs magic
1999-12-16 Havoc Pennington <hp@redhat.com>
* src/file-manager/desktop-canvas.h: Added API for controlling the
background, so we can connect that to the IDL interface.
* src/file-manager/desktop-canvas.h: New file
* src/file-manager/desktop-window.h: tweaks
* idl/gnome-desktop.idl: Change BackgroundInfo to not be a union.
1999-12-16 John Sullivan <sullivan@eazel.com>
* src/file-manager/fm-directory-view.c (directory_load_cb):
changed assert to warning
1999-12-16 Elliot Lee <sopwith@redhat.com>
* components/help/hyperbola-nav-tree.c: Translate strings.
* components/history/ntl-history-view.c: Bug fixes, use API
function for setting meta-view label.
* libnautilus/ntl-meta-view-client.[ch]:
s/meta_view_set_label/meta_view_client_set_label/
* src/ntl-uri-map.c: Use history view instead of help view as the
default meta view for now.
* src/ntl-window.c: As per the comment that was removed from
ntl-window.c, gnome_app_install_menu_hints() needs to be called
_after_ statusbar creation
* src/file-manager/fm-directory-view.c: Add more debugging assertions
and messages.
1999-12-15 John Sullivan <sullivan@eazel.com>
* src/ntl-window.c: (nautilus_window_constructed): Added beginnings
of a menu bar, and reorganized toolbar a little. There's a rudimentary
File menu now. The View As option menu moved down to the location bar
line. This is by no means a complete or final organization, but it's
a start.
* (file_menu_close_cb): new callback for File/Close menu item
* (file_menu_exit_cb): new callback for File/Quit menu item
* file_menu_info[]: new GNOMEUIINFO struct for File menu
* toolbar_info[]: new GNOMEUIINFO struct for toolbar
1999-12-15 Elliot Lee <sopwith@redhat.com>
* Warning fixes throughout.
* Use $(WERROR) in Makefiles to get -Werror.
1999-12-16 00:02:40 +00:00
1999-12-15 Darin Adler <darin@eazel.com>
* components/help/.cvsignore: Ignore more generated files.
* components/help/hyperbols-filefmt.c: Fix warnings.
* components/help/hyperbols-main.c: Fix warnings.
* components/help/hyperbols-nav-tree.c: Fix warnings.
1999-12-15 Elliot Lee <sopwith@redhat.com>
* components/Makefile.am: Turn on compilation of hyperbola component.
* components/help/*: Compile and run.
* libnautilus/ntl-meta-view-client.c: Create & set the property bag if it doesn't exist.
* src/ntl-uri-map.c: Load the hyperbola nav tree component as a test meta view.
* src/ntl-view.c: Fill in NULL fields with empty strings, so that ORBit doesn't segfault.
* src/ntl-window-msgs.c: When creating new meta views, they should
be meta views and not content views (cut & paste error).
* src/file-manager/fm-directory-view.c: Don't redisplay every time a new entry comes in.
1999-12-15 Darin Adler <darin@eazel.com>
* configure.in: Turned "-Wshadow" and "-Wundef" off for now, since they
fire in some existing code.
* gnome-icon-container.c: (handle_icon_button_press): Null out the drag
variables before sending the activate signal. This makes activating an
icon with a double-click work without crashing.
* ntl-main.c: (main): Make critical and warning messages fatal if
NAUTILUS_DEBUG is set in the environment. Make sure you have a new
gnome-vfs that doesn't use g_warning for status messages.
* ntl-window-msgs.c: (nautilus_window_change_location_internal):
Made the history store away the current position as the new "previous"
instead of storing away the new position. This makes the forward and
back buttons work better.
* ntl-window.c: (nautilus_window_back, nautilus_window_fwd):
Had to make a corresponding change here after the change to the
history mechanism.
* fm-directory-view.c: (display_selection_info): Some fixes to the
selection info display: "file"/"files" was backwards, text said "in"
before the file size, and the display was not cleared when the
selection was made empty. I still see problems where the selection
info gets cleared when the window is lowered and then raised.
1999-12-15 Andy Hertzfeld <andy@eazel.com>
* my first change: changed ntl-window-state.c
(nautilus_window_set_initial_state): changed initial path
to be the user's home directory, getting rid of confusing "localhost"
1999-12-15 Elliot Lee <sopwith@redhat.com>
* configure.in: Add --enable-more-warnings and --enable-fatal-warnings switches.
* src/ntl-uri-map.c: Add comment about functionality-in-waiting.
1999-12-15 Darin Adler <darin@eazel.com>
* libnautilus/gtkscrollframe.c (gtk_scroll_frame_size_allocate):
Rolled out my change. I was confused. Elliot had this fixed
already but I forgot to "make install".
1999-12-15 Darin Adler <darin@eazel.com>
* libnautilus/gtkscrollframe.c (gtk_scroll_frame_size_allocate):
Fixed overflow problem caused by gint16 local variable.
1999-12-15 Darin Adler <darin@eazel.com>
* src/ntl-window.c (nautilus_window_constructed):
Fixed signal handler to point to nautilus_window_goto_url_cb
instead of nautilus_window_goto_url. This was causing a bad
cast when a new URL was typed.
1999-12-15 Darin Adler <darin@eazel.com>
* src/ntl-uri-map.c (nautilus_navinfo_new): Changed back to
const gchar*. To compile, you need to install the latest
gnome-vfs.
1999-12-15 Elliot Lee <sopwith@redhat.com>
* libnautilus/gtkscrollframe.c: Fix size_allocate.
1999-12-14 Maciej Stachowiak <mjs@eazel.com>
* src/ntl-uri-map.c (nautilus_navinfo_new): a const char* can't be
passed where a gchar* is expected.
1999-12-14 Darin Adler <darin@eazel.com>
* configure.in: Turned on more warnings, including -Werror.
I found one or two real bugs, and made some minor changes
to quiet the compiler so I could turn on some useful warnings
that triggered on the existing code.
* src/file-manager/dfos-xfer.c: (handle_xfer_vfs_error):
Fixed a place where it was calling the gnome error(), but using
the parameters from the old gnome-fm error() function.
* libnautilus/ntl-meta-view-client.c:
(nautilus_meta_view_set_label): Fixed a place where we
were passing in string literals to code that will free them.
We need to call g_strdup before passing them to gnome_property_bag_add.
* libnautilus/gnome-icon-container.c: Fixed a warning.
* libnautilus/gtkscrollframe.c: Fixed a warning.
* libnautilus/ntl-content-view-client.c: Fixed a warning.
* libnautilus/ntl-view-client.c: Fixed a warning.
* libnautilus/ntl-content-view.c: Fixed a warning.
* src/ntl-main.c: Fixed a warning.
* src/ntl-meta-view.c: Fixed a warning.
* src/ntl-types.h: Fixed a warning.
* src/ntl-view.c: Fixed a warning.
* src/ntl-window.c: Fixed a warning.
* src/file-manager/dfos-xfer-progress-dialog.c: Fixed a warning.
* src/file-manager/fm-icon-cache.c: Fixed a warning.
1999-12-14 Elliot Lee <sopwith@redhat.com>
* src/*.c: Restructure the whole NautilusWindow code for sanity's sake.
* src/ntl-uri-map.[ch]: Instead of just passing in various pieces of information about the old URL,
pass in the Nautilus_NavigationInfo that has to be kept around anyways.
* idl/nautilus.idl: Allow a selection to be multiple URI's.
1999-12-15 00:04:42 +00:00
1999-12-14 Darin Adler <darin@eazel.com>
* src/ntl-window.c: (nautilus-window-constructed): Forward-button signal
was connected with NULL parameter instead of window. Fixed that so it
has a chance of working.
* .cvsignore: Ignore more generated files.
* components/.cvsignore: Ignore more generated files.
* help/.cvsignore: Ignore more generated files.
* history/.cvsignore: Ignore more generated files.
* icons/.cvsignore: Ignore more generated files.
* idl/.cvsignore: Ignore more generated files.
* libnautilus/.cvsignore: Ignore more generated files.
* src/.cvsignore: Ignore more generated files.
* src/file-manager/.cvsignore: Ignore more generated files.
1999-12-14 John Sullivan <sullivan@eazel.com>
* src/ntl-window.c: (nautilus-window-constructed): Reordered option menu
creation code to fix bug where it wasn't sizing itself properly. Changed
label of placeholder item and desensitized it to make it more obvious that
it's a non-working placeholder.
1999-12-14 Elliot Lee <sopwith@redhat.com>
* configure.in, Makefile.am, icons/: Add icons
* src/file-manager/fm-directory-view.c: Everything goes inside the scroll-frame, not the view itself.
1999-12-13 Elliot Lee <sopwith@redhat.com>
* libnautils/g*.[ch]: Switch from imlib to pixbuf.
* src/file-manager: Import from gnome-fm.
* idl/nautilus.idl: Add a 'main_window' attribute on a ViewFrame, so that views can talk to the main window.
1999-12-10 Elliot Lee <sopwith@redhat.com>
* libnautilus/ntl-meta-view.[ch]: Add a convenience function for
setting the label.
* Throughout: Rename the meta view "description" property to "label",
which more accurately describes its use.
* components/help: Start turning hyperbola into component.
1999-12-09 Elliot Lee <sopwith@redhat.com>
* Start migration from gnome-fm.
src/explorer-location-bar.[ch]:
Copy over from gnome-fm, change signal to include new URI.
src/ntl-window.c:
Make NautilusWindow use it.