Commit graph

262 commits

Author SHA1 Message Date
Andy Hertzfeld
eecee1352e moved pixbuf manipulation routines into
moved pixbuf manipulation routines into
      libnautilus/nautilus-graphic-effects
2000-03-25 00:36:57 +00:00
Darin Adler
433efe122f Fixed bug 334 (Need proper hit detection when hit-testing icons.
* libnautilus/nautilus-icon-canvas-item.c: (hit_test_pixbuf):
	Fixed a typo-type error where we were checking every pixel of the
	pixbuf instead of only the pixels that we were hit testing against.

	* libnautilus/nautilus-icon-container.c: Tweaks.
2000-03-22 19:36:44 +00:00
John Sullivan
212ed01c76 Emit SELECTION_CHANGED signal after changing selection via keyboard. 2000-03-22 01:39:57 +00:00
Pavel Cisler
f713422616 Fixed an annoying bug that would sometimes cause the drag&drop feedback to
2000-03-21  Pavel Cisler  <pavel@eazel.com>

	Fixed an annoying bug that would sometimes cause the drag&drop feedback
	to come up delayed.
2000-03-22 00:45:56 +00:00
Darin Adler
1764f21218 Did some of the items from RENAMING.
* libnautilus/Makefile.am:
	* libnautilus/gnome-icon-container-dnd.c:
	* libnautilus/gnome-icon-container-dnd.h:
	* libnautilus/gnome-icon-container-grid.c:
	* libnautilus/gnome-icon-container-grid.h:
	* libnautilus/gnome-icon-container-private.h:
	* libnautilus/gnome-icon-container.c:
	* libnautilus/gnome-icon-container.h:
	* libnautilus/gtkflist.c:
	* libnautilus/gtkflist.h:
	* libnautilus/nautilus-icon-canvas-item.c:
	* libnautilus/nautilus-icon-canvas-item.h:
	* libnautilus/nautilus-icon-container.c:
	* libnautilus/nautilus-icon-container.h:
	* libnautilus/nautilus-icon-dnd.c:
	* libnautilus/nautilus-icon-dnd.h:
	* libnautilus/nautilus-icon-grid.c:
	* libnautilus/nautilus-icon-grid.h:
	* libnautilus/nautilus-icon-private.h:
	* libnautilus/nautilus-icons-view-icon-item.c:
	* libnautilus/nautilus-icons-view-icon-item.h:
	* libnautilus/nautilus-lib-self-check-functions.h:
	* libnautilus/nautilus-list-column-title.c:
	* libnautilus/nautilus-list.c:
	* libnautilus/nautilus-list.h:
	* src/file-manager/Makefile.am:
	* 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:
	* src/file-manager/fm-icon-view.c:
	* src/file-manager/fm-icon-view.h:
	* src/file-manager/fm-list-view.c:
	* src/file-manager/fm-list-view.h:
	* src/ntl-app.c:
	Did these RENAMING entries:
	  FMDirectoryViewIcons -> FMIconView
	  FMDirectoryViewList  -> FMListView
	  GnomeIconContainer -> NautilusIconContainer
	  GnomeIconContainerIcon -> NautilusIcon
	  NautilusIconsViewIconItem -> NautilusIconCanvasItem

	* RENAMING: Marked the renaming done.
2000-03-22 00:29:07 +00:00
Darin Adler
f09362cb59 Fixed arrow keys and worked on the icon grid.
Fixes bugs #314, #324, and #325.

	* components/help/hyperbola.goad:
	Corrected repo_ids -> repo_id, reported by Richard Hult.

	* src/nautilus.goad:
	Added missing = character, reported by Richard Hult.

	* libnautilus/gnome-icon-container-grid.c:
	* libnautilus/gnome-icon-container-grid.h:
	* libnautilus/gnome-icon-container.c:
	* libnautilus/gnome-icon-container-private.h:
	Made the icon grid handle negative coordinates.
	Removed most of the icon grid code.
	Reimplemented the arrow keys. They should work again.

	* libnautilus/nautilus-gnome-extensions.c:
	* libnautilus/nautilus-gnome-extensions.h:
	(nautilus_art_irect_contains_irect):
	Added another helper function.

	* libnautilus/nautilus-icons-view-icon-item.c:

	* libnautilus/nautilus-icons-view-icon-item.h:
	* libnautilus/gnome-icon-container.c:
	* libnautilus/gnome-icon-container-private.h:
	Added user data to each canvas item and got rid of the hash table
	that maps canvas items to icons.

	* RENAMING: Tweaks.
2000-03-21 23:18:01 +00:00
Pavel Cisler
ec8d277e18 Center the sort order indicators inside a title better. Make the column
2000-03-20  Pavel Cisler  <pavel@eazel.com>

	Center the sort order indicators inside a title better. Make the column
	title label spacing more like the old CtkCList.
2000-03-21 03:19:17 +00:00
Pavel Cisler
a4b40782db Use an offscreen bitmap to draw the column title during column resizing
2000-03-20  Pavel Cisler  <pavel@eazel.com>

	Use an offscreen bitmap to draw the column title during column resizing
	and column prelighting.
2000-03-21 02:40:52 +00:00
Darin Adler
857e8fa26b Fixed the "tall line of icons" bug.
* libnautilus/gnome-icon-container-grid.h:
	* libnautilus/gnome-icon-container-grid.c:
	* libnautilus/gnome-icon-container.c:
	Rewrote the routines to not have a separate concept of the
	actual grid height and the allocated grid height. Most important
	change was to update the first_free variables when resizing.

	* src/file-manager/fm-directory-view-icons.h:
	* src/file-manager/fm-directory-view-icons.c:
	(fm_directory_view_icons_line_up_icons):
	Removed the unused line_up_icons call. This feature will return,
	but for now it's just a waste of space.
2000-03-18 00:46:16 +00:00
Darin Adler
e8fcc82dff Simplified the grid a bit and did some redesign. The grid now takes into
* libnautilus/gnome-icon-container-grid.h:
	* libnautilus/gnome-icon-container-grid.c:
	* libnautilus/gnome-icon-container-private.h:
	* libnautilus/gnome-icon-container.c:
	* libnautilus/nautilus-icons-view-icon-item.c:
	* libnautilus/nautilus-icons-view-icon-item.h:
	Simplified the grid a bit and did some redesign. The grid now
	takes into account the height and width of the icons. More work
	to come.

	* libnautilus/nautilus-global-preferences.c:
	* nautilus-widgets/nautilus-preferences.h:
	Some cleanup, including types for constants.

	* libnautilus/nautilus-gnome-extensions.h:
	* libnautilus/nautilus-gnome-extensions.c:
	(nautilus_art_irect_equal), (nautilus_art_drect_equal),
	(nautilus_gnome_canvas_item_get_current_canvas_bounds),
	(nautilus_gnome_canvas_item_request_redraw),
	(nautilus_gnome_canvas_request_redraw_rectangle),
	(nautilus_gnome_canvas_item_get_world_bounds):
	More useful canvas and libart routines.

	* RENAMING: More renaming ideas.
2000-03-17 23:03:39 +00:00
Elliot Lee
bf66a469cc #include <string.h>
#include <string.h>
2000-03-17 22:40:55 +00:00
Pavel Cisler
aa98d924c7 Fix some bugs that John kindly uncovered.
2000-03-17  Pavel Cisler  <pavel@eazel.com>

	Fix some bugs that John kindly uncovered.
2000-03-17 19:19:40 +00:00
Pavel Cisler
53aa5a6308 First pass on making list column resizing live.
2000-03-16  Pavel Cisler  <pavel@eazel.com>

	First pass on making list column resizing live.

	* libnautilus/Makefile.am
	* libnautilus/nautilus-list-column-title.c
	* libnautilus/nautilus-list-column-title.h
	* libnautilus/gtkflist.h
	* libnautilus/gtkflist.c
	* manager/fm-directory-view-list.c
	* libnautilus/nautilus-gdk-extensions.c
	* libnautilus/nautilus-gdk-extensions.h
2000-03-17 04:46:16 +00:00
Darin Adler
8efa4d71d7 Did some of the renamings that were queued in RENAMING.
* libnautilus/Makefile.am:
	* libnautilus/gdk-extensions.c:
	* libnautilus/gdk-extensions.h:
	* libnautilus/nautilus-gdk-extensions.c:
	* libnautilus/nautilus-gdk-extensions.h:
	* libnautilus/gnome-icon-container.c:
	* libnautilus/nautilus-background.c:
	* libnautilus/nautilus-icons-view-icon-item.c:
	Renamed gdk-extensions to add the nautilus- prefix and changed
	all includers.

	* src/Makefile.am:
	* src/explorer-location-bar.c:
	* src/explorer-location-bar.h:
	* src/nautilus-location-bar.c:
	* src/nautilus-location-bar.h:
	* src/ntl-window-msgs.c:
	* src/ntl-window.c:
	Renamed ExplorerLocationBar to NautilusLocationBar.

	* src/Makefile.am:
	* src/nautilus-bookmarklist.c:
	* src/nautilus-bookmarklist.h:
	* src/nautilus-bookmark-list.c:
	* src/nautilus-bookmark-list.h:
	* src/nautilus-bookmarks-window.c:
	* src/nautilus-bookmarks-window.h:
	* src/nautilus-window-menus.c:
	Renamed NautilusBookmarklist to NautilusBookmarkList.

	* RENAMING: Marked items done and added some new ones.

	* nautilus-widgets/nautilus-preferences-item.c:
	* nautilus-widgets/nautilus-preferences.c:
	* nautilus-widgets/test-nautilus-widgets.c:
	* libnautilus/nautilus-icon-factory.c:
	* src/file-manager/fm-directory-view-icons.c:
	* src/file-manager/fm-directory-view.c:
	* src/file-manager/fm-icon-text-window.c:
	Cleaned up the interface to NautilusPreferences a bit.
2000-03-16 21:10:42 +00:00
John Sullivan
3ffd225184 Fixes for a couple of preferences bugs. 2000-03-16 20:10:13 +00:00
John Sullivan
c821dce685 Moved a couple of utility functions into the right libnautilus homes. 2000-03-16 18:16:58 +00:00
John Sullivan
0437a094a6 Make icon theme changes persist by using preferences mechanism. 2000-03-16 17:13:49 +00:00
Darin Adler
ee495dba40 Tell people about the gnome-xml branch.
* HACKING: Tell people about the gnome-xml branch.

	* libnautilus/Makefile.am:
	* libnautilus/gnome-icon-container-grid.c:
	* libnautilus/gnome-icon-container-grid.h:
	* libnautilus/gnome-icon-container-private.h:
	* libnautilus/gnome-icon-container.c:
	Broke out the grid code from the main container code.
	This is a first step toward improving the layout code.

	* libnautilus/nautilus-directory-private.h:
	* libnautilus/nautilus-directory.c:
	* libnautilus/nautilus-directory.h:
	* src/fm-directory-view.c:
	Got started on making the directory I/O async.
	There's still a long way to go, this was a baby step.

	* libnautilus/nautilus-bookmark.c:
	* libnautilus/nautilus-bookmark.h:
	* libnautilus/nautilus-self-checks.c:
	General cleanup.

	* libnautilus/nautilus-file.h:
	Rearranged a little bit.

	* libnautilus/nautilus-file-utilities.c:
	Put FIXME in where there's code that needs to be changed.
2000-03-16 00:31:18 +00:00
John Sullivan
4df4c1e1ea Used preferences mechanism for text under icons and
open-in-new-window-when-clicked.
2000-03-15 21:13:57 +00:00
Darin Adler
b84f3f1d7d A quick cleanup of how we use gnome-xml.
* libnautilus/Makefile.am:
	* libnautilus/nautilus-xml-extensions.c:
	* libnautilus/nautilus-xml-extensions.h:
	Added some new gnome-xml helper functions.

	* libnautilus/nautilus-directory.c:
	(nautilus_directory_get_file_metadata_node):
	* libnautilus/nautilus-file.c:
	(nautilus_file_get_keywords):
	(nautilus_file_set_keywords):
	* libnautilus/nautilus-icon-factory.c:
	(get_child_node_by_property):
	(get_themed_icon_file_path):
	* src/nautilus-bookmarklist.c:
	(nautilus_bookmarklist_load_file):
	Changed to use the new helper functions.

	* src/nautilus-bookmarklist.c:
	(nautilus_bookmarklist_save_file): Changed direct uses of root to
	use xmlDocGet/SetRootElement while I was editing the file.  I
	think this is the same change Pavel made but wasn't able to check
	in.

	* src/nautilus-bookmarklist.c:
	General cleanup.
2000-03-15 16:46:51 +00:00
Darin Adler
bdf3c6c136 Added additional data to icons so they can specify where the
embedded text fits in each icon.

	* icons/eazel/Makefile.am, icons/eazel/i-regular.xml: Added the
	file to specify attributes of icons. Specifically added the
	attribute that says there is space for embedded text in the
	Eazel-theme regular icon.

	* libnautilus/nautilus-icon-factory.h:
	* libnautilus/nautilus-icon-factory.c:
	(get_child_node_by_property), (get_themed_icon_file_path),
	(get_icon_file_path), (nautilus_icon_factory_get_thumbnail_uri),
	(load_specific_image), (load_image_for_scaling),
	(get_image_from_cache), (load_image_scale_if_necessary),
	(nautilus_icon_factory_get_pixbuf_for_icon),
	(nautilus_icon_factory_get_pixbuf_for_file):
	Added code to read a rectangle for the embedded text along with
	the icon, cache it with the icon, scale it with the icon, and
	return it to the caller along with the icon.

	* libnautilus/nautilus-icons-view-icon-item.c:
	(nautilus_icons_view_icon_item_initialize_class),
	(nautilus_icons_view_icon_item_set_arg),
	(nautilus_icons_view_icon_item_get_arg),
	(nautilus_icons_view_icon_item_get_image),
	(nautilus_icons_view_icon_item_set_image),
	(nautilus_art_irect_to_gdk_rectangle),
	(draw_mini_text), (draw_embedded_text),
	(nautilus_icons_view_icon_item_draw):
	Changed the code that draws the embedded text to respect the
	text rectangle passed in. Changed the pixbuf setting to use a
	function instead of the arg interface and take a text rectangle
	along with the pixbuf.

	* libnautilus/gnome-icon-container-dnd.c
	(gnome_icon_container_dnd_begin_drag):
	* libnautilus/gnome-icon-container.c:
	(icon_get_actual_size): Got rid of callers who were using the arg
	interface to get at the image of an icon
	("NautilusIconsViewIconItem::pixbuf").

	* src/file-manager/fm-directory-view-icons.c:
	(get_icon_property_cb): Get rid of hard-coded rule that only
	themes with eazel at the front of their names can display text
	inside the icons.

	* libnautilus/gnome-icon-container.c:
	(icon_new): Fixed a bug where icons would be super-tiny if they
	got too big, like if you entered a directory that was zoomed all
	the way in.
	(start_stretching), (ungrab_stretch_icon), (end_stretching),
	(gnome_icon_container_show_stretch_handles): Added code to grab
	the pointer while stretching an icon.
	(item_event_cb): Added a return statement that John forgot when
	he was editing. Without that, it was falling through to the next
	case, which had the same effect anyway.
	(update_icon): Pass the text rectangle through from the icon
	factory to the icon canvas item, using the new call instead of the
	old arg interface approach.

	* components/help/.cvsignore: Added entries for
	.la and .lo files.

	* components/help/Makefile.am:
	* components/help/hyperbola-nav-index.c:
	* components/help/hyperbola-nav-search.c:
	* libnautilus/nautilus-directory-private.h:
	* libnautilus/nautilus-directory.c:
	* src/nautilus-bookmarklist.c:
	Fixed flags for gnome-xml
	includes. Someone pointed out that you are supposed to include
	these as "#include <tree.h>", not "#include <gnome-xml/tree.h>" so
	I fixed our uses to work that way.

	* libnautilus/nautilus-directory.c:
	(nautilus_directory_get_file_metadata_node): Fixed code that was
	destroying something allocated by gnome-xml with g_free instead
	of xmlFree.

	* libnautilus/nautilus-file.c:
	(nautilus_file_get_keywords), (nautilus_file_set_keywords):
	Fixed storage leak where we were getting a property and not freeing it.

	* libnautilus/nautilus-default-file-icon.h:
	* libnautilus/nautilus-default-file-icon.c:
	* libnautilus/nautilus-icon-factory.c:
	(load_image_for_scaling): Got rid of the global that tells whether
	the default icon has an alpha channel -- it's not hardwired TRUE.
2000-03-15 00:31:49 +00:00
John Sullivan
ea7cd874d3 Made directories start up using the same view they were last displayed with. 2000-03-14 21:56:24 +00:00
John Sullivan
f499337913 Fixed bug where selection-dependent menu items (e.g. "Open in New Window")
didn't update after deleting selected items.
2000-03-14 19:33:20 +00:00
Jonathan Blandford
87179b7dca Add a gtk_drag_finish to hopefully solve half the flying windows problem.
2000-03-14  Jonathan Blandford  <jrb@redhat.com>

	* libnautilus/gnome-icon-container-dnd.c (drag_drop_cb): Add a
	gtk_drag_finish to hopefully solve half the flying windows
	problem.  Needs more thought then this, though...
2000-03-14 18:58:56 +00:00
John Sullivan
92dc45caa1 Fixed two-popup-menus-at-once bug. 2000-03-14 17:50:59 +00:00
John Sullivan
98916dd8ca Improvements & bug fixes to keyboard navigation in file manager. 2000-03-14 05:55:03 +00:00
Darin Adler
ec73da2452 Fixed bug that caused a core dump when getting at the root directory
* libnautilus/nautilus-directory.c (nautilus_directory_get):
	Fixed bug that caused a core dump when getting at the root
	directory because all the '/' characters were stripped off
	the URI.

	* /src/file-manager/fm-directory-view.c:
	* nautilus-widgets/nautilus-preferences.c:
	Tiny formatting fixes.
2000-03-13 22:48:12 +00:00
Darin Adler
fe7c58d2d1 A quick cleanup pass on the NautilusStringList class: Changed uses of
* libnautilus/nautilus-string-list.h:
	* libnautilus/nautilus-string-list.c:
	A quick cleanup pass on the NautilusStringList class:
	Changed uses of gchar to char, changed g_assert to g_return_if_fail
	as appropriate. Fixed brace style to be emacs-friendly (open brace
	on same line as if statement). Fixed spelling of delimiter.
	Got rid of some unnecessary special cases for NULL and sped up
	the _equal function be eliminating the redundant length check.
	Changed the self-check so that it doesn't write a warning to the
	log when it runs.
2000-03-13 16:41:09 +00:00
Ramiro Estrugo
e58c19a4b3 libnautilus/nautilus-global-preferences.c, Add a table of meta view iids
* libnautilus/nautilus-global-preferences.c,
* libnautilus/nautilus-global-preferences.h:
(nautilus_global_preferences_get_meta_view_iids) Add a table of
meta view iids and a function to retrieve them.  This is a hack
until we have better runtime detection of components.
Add some better defaults for which meta views are shown.  By
default none were shown.  Undo a previous gnome_config default
hack.  There is now a better fix in place in the prefs code.

* nautilus-widgets/nautilus-preferences.c:
(nautilus_preferences_make_gnome_config_string) A new function to
make a string as expected by gnome_config with a trailing default
value.  Use this string to fetch the value of the preferences.

* src/Makefile.am,
src/ntl-prefs.c,
src/ntl-prefs.h,
src/nautilus-window-menus.c,
src/nautilus.h:
Retire ntl-prefs.c and ntl-prefs.h.  Remove these 2 from build and
all references to them.

* src/ntl-app.c:
(nautilus_app_startup, nautilus_app_destroy) No need to call
retired ntl-prefs functions.

* src/ntl-uri-map.c:
(add_meta_view_iids_from_preferences): New function.  Factor out
meta iid setup code into one place.  Replace the static meta iid
setup code with something that looks in preferences to see which
meta views are enabled.  Next step is to make the meta view
respond to pref changes.
2000-03-13 01:37:44 +00:00
Ramiro Estrugo
358ad2c9ca Properly remove the item from the list so that we dont crash later trying
* nautilus-widgets/nautilus-preferences.c:
(pref_hash_info_remove_callback) Properly remove the item from
the list so that we dont crash later trying to munge a NULL node.

* libnautilus/nautilus-global-preferences.h:
(NAUTILUS_PREFERENCES_USER_LEVEL) Make sure the user level
defaults to hacker.
2000-03-12 22:47:05 +00:00
Ramiro Estrugo
7398417988 Call clear() from free() instead of duplicating the work. 2000-03-12 21:20:04 +00:00
Ramiro Estrugo
29bb801957 *libnautilus/Makefile.am: Added nautilus_string_table
*libnautilus/nautilus-lib-self-check-functions.h: Added string
table tests hooks.

*libnautilus/nautilus-string-list.c,
libnautilus/nautilus-string-list.h: New class to deal with lists
of strings in a type safe manner.  Also added self tests for this
class.
2000-03-12 21:16:43 +00:00
Ramiro Estrugo
b657b1fef3 Make the preference changes persistent.
* nautilus-widgets/nautilus-preferences.c:
(prefs_set_pref, nautilus_preferences_register_from_info,
nautilus_preferences_register_from_values): Make the preference
changes persistent.

*nautilus-widgets/nautilus-preferences-item.c,
nautilus-widgets/nautilus-preferences-item.h,
nautilus-widgets/nautilus-preferences.c,
nautilus-widgets/nautilus-preferences.h,
nautilus-widgets/test-nautilus-widgets.c:
Dont use GtkFunadamentalType, since we obviously wont support
all fundamantal gtk types as preferences.  Use an enum instead.
Makes the preferences type whacking code exactly 14.85% more type
safe.
2000-03-12 21:13:41 +00:00
Ramiro Estrugo
e7477fb6ef (nautilus_user_top_directory): New function. Used to obtain
the user's "top" directory.  The top directory is an alternative
home place for naive users.
2000-03-12 17:56:46 +00:00
Ramiro Estrugo
42550b2c43 Use better names for the global preferences macros.
New method for removing callbacks.
Filter files according to the user level.
Add/Remove a preferences callback to keep track of user level changes.
2000-03-12 16:53:35 +00:00
Ramiro Estrugo
63c6d54af8 Moved global preferences to libnautilus. 2000-03-12 12:58:20 +00:00
Darin Adler
374870d5ab Fixed typo that broke all hit testing except for rubber band selection!
* libnautilus/nautilus-icons-view-icon-item.c
	(nautilus_icons_view_icon_item_point):
	Fixed typo that broke all hit testing except for rubber band
	selection! (Sorry.)

	* libnautilus/gnome-icon-container-dnd.c
	(set_gnome_icon_list_selection, set_uri_list_selection),
	libnautilus/gnome-icon-container-private.h,
	libnautilus/gnome-icon-container.h,
	libnautilus/gnome-icon-container.c
	(gnome_icon_container_get_icon_uri,
	gnome_icon_container_initialize_class, gnome_icon_container_new,
	update_icon, gnome_icon_container_update,
	gnome_icon_container_request_update),
	src/file-manager/fm-directory-view-icons.c (create_icon_container,
	get_icon_images_cb, get_icon_uri_cb, get_icon_text_cb,
	get_icon_property_cb): Change code that used to use a separate
	controller object to just use signals on the icon container
	instead.

	* libnautilus/nautilus-gtk-extensions.h,
	libnautilus/nautilus-gtk-extensions.c,
	src/file-manager/fm-directory-view.c: Add new signal marshal
	functions as needed and changed the name of one of the old
	functions.

	* libnautilus/Makefile.am,
	libnautilus/nautilus-icons-controller.h,
	libnautilus/nautilus-icons-controller.c,
	src/file-manager/Makefile.am,
	src/file-manager/fm-icons-controller.h,
	src/file-manager/fm-icons-controller.c: Removed the old controller
	object, it was a bad idea.
2000-03-11 00:46:40 +00:00
Darin Adler
bddcc07d4b Fixed rubber banding to hit test with all the parts of the icon, not just
* libnautilus/Makefile.am, libnautilus/gnome-icon-container-dnd.c
	  (set_gnome_icon_list_selection,
	  gnome_icon_container_dnd_begin_drag),
	  libnautilus/gnome-icon-container.c (icon_is_in_region,
	  start_stretching), libnautilus/nautilus-icons-view-icon-item.h,
	  libnautilus/nautilus-icons-view-icon-item.c (hit_stretch_handle,
	  hit_test_pixbuf, hit_test, nautilus_icons_view_icon_item_point,
	  nautilus_icons_view_icon_item_get_icon_world_rectangle,
	  nautilus_icons_view_icon_item_get_icon_rectangle,
	  nautilus_icons_view_icon_item_get_icon_window_rectangle,
	  nautilus_icons_view_icon_item_get_hit_stretch_handle,
	  hit_stretch_handle,
	  nautilus_icons_view_icon_item_hit_test_stretch_handles,
	  nautilus_icons_view_icon_item_hit_test_rectangle):
	Fixed rubber banding to hit test with all the parts of the icon,
	not just the icon pixbuf itself. Did this by changing all the
	internal hit testing to use rects instead of points. At the same
	time changed the external interface to always use world
	coordinates for clarity.

	* libnautilus/nautilus-directory.c (compare_file_with_name),
	libnautilus/nautilus-file.c (nautilus_file_set_keywords): Fixed
	some void * problems that upset newer versions of GCC but not the
	older one that I'm using.

	* libnautilus/nautilus-gtk-extensions.h,
	libnautilus/nautilus-gtk-extensions.c: Formatting and include
	statements fix up.
2000-03-10 22:47:48 +00:00
Jonathan Blandford
d21681ac5d Avoid a bug where we get stuck grabs when you double click.
2000-03-10  Jonathan Blandford  <jrb@redhat.com>

	* libnautilus/gnome-icon-container.c (button_press_event): Avoid a
	bug where we get stuck grabs when you double click.
2000-03-10 21:19:06 +00:00
Maciej Stachowiak
c81f075c88 store zoom_control object in the window.
* src/ntl-window.c, src/ntl-window.h: store zoom_control object in
	the window.

	* src/nautilus-zoomable-frame-svr.c: New file; implement CORBA
	server for Nautilus::ZommableFrame interface.
	* src/ntl-view-private.h: prototypes for shared stuff needed to make
	this work.
	* src/ntl-view.c: Attach a Nautilus::ZoomableFrame interface to
	the Nautilus::ViewFrame.

	* libnautilus/nautilus-gtk-extensions.h,
	libnautilus/nautilus-gtk-extensions.c
	(nautilus_gtk_marshal_NONE__DOUBLE): New function.
2000-03-10 15:32:03 +00:00
Darin Adler
5f4af6f1ea It turns out that you aren't intended to reset the scroll region once you
* libnautilus/gnome-icon-container.c (set_scroll_region):
	It turns out that you aren't intended to reset the scroll region
	once you have items in the canvas. We need to do that, so I had
	to write some code that would update all the items when that happens.

	* libnautilus/nautilus-icons-view-icon-item.c:
	(recompute_bounding_box): Rewrote this to not assume that the
	icon items are all top-level items.
	(compute_text_rectangle, hit_test,
	nautilus_icons_view_icon_item_bounds): Change hit testing so
	it includes hits on the text. The rubberband still has to be
	fixed so it doesn't have the same problem.

	* libnautilus/nautilus-file.c: Improved a comment.

	* RENAMING: Some more name changes.
2000-03-10 03:20:54 +00:00
John Sullivan
30433daf59 Fixed mistake in recent bug fix. 2000-03-10 02:44:52 +00:00
John Sullivan
0d911a35c0 Fixed storage leak in nautilus_file_list_unref, and added some more self checks. 2000-03-10 01:38:10 +00:00
Andy Hertzfeld
5515799d9f 2 small fixes: tweaked constants used for pre-lighting icons and fixed bug
2 small fixes:  tweaked constants used for pre-lighting icons and
	fixed bug in music view where track numbers were displayed as -1 if
	they were not present in the id3 data; now they are blank.
2000-03-10 00:53:01 +00:00
Maciej Stachowiak
7d9696ef0f Pass the correct thing as the servant to avoid crashing on instantiation.
* libnautilus/nautilus-zoomable.c
	(impl_Nautilus_Zoomable__create): Pass the correct thing as the
	servant to avoid crashing on instantiation.
	(nautilus_zoomable_real_set_bonobo_control): ref and sink the
	BonoboControl Gtk object.
	(nautilus_zoomable_destroy): unref the control instead of
	destroying.
2000-03-10 00:46:31 +00:00
Darin Adler
bcf419e81d Andy's check-in yesterday accidentally rolled out some changes to this
* nautilus-icons-view-icon-item.c (emblem_layout_next,
	nautilus_icons_view_icon_item_bounds):
	Andy's check-in yesterday accidentally rolled out some changes
	to this file. The changes include the typos that John and I had
	fixed in emblem_layout_next and nautilus_icons_view_icon_item_bounds.

	* nautilus-icons-view-icon-item.c:
	As Andy was about to do anyway, I tightened up the emblem
	positioning so they are closer to each other by changing the
	hard-coded constant EMBLEM_SPACING.
2000-03-09 21:09:20 +00:00
Darin Adler
8656eb9d85 Fixed bugs relating to multiple directory and file objects for the same
* libnautilus/nautilus-directory-private.h,
	libnautilus/nautilus-directory.c, libnautilus/nautilus-file.c
	(nautilus_directory_find_file, compare_file_with_name,
	nautilus_directory_get, nautilus_file_get): Fixed bugs relating to
	multiple directory and file objects for the same entity. Stripped
	trailing '/' characters in nautilus_directory_get and changed
	nautilus_file_get to return already-existing files instead of
	always creating new ones. Added self-checks to make sure this
	works.

	* libnautilus/nautilus-directory.c
	(nautilus_directory_try_to_read_metafile): Fixed bug where
	metafile reading would fail. The gnome-xml parser requires a null
	character at the end of the file, even though the size is passed
	in!

	* libnautilus/nautilus-directory.c
	(nautilus_directory_remove_write_metafile_idle,
	nautilus_directory_finalize,
	nautilus_directory_try_to_write_metafile,
	nautilus_directory_request_write_metafile, ): Changed metafile
	writing so it always happens at idle time.

	* libnautilus/nautilus-directory.c
	(nautilus_directory_try_to_read_metafile): Fixed bug where
	metafile reading would fail. The gnome-xml parser requires a null
	character at the end of the file, even though the size is passed
	in!

	* libnautilus/nautilus-lib-self-check-functions.h: Changed order
	so lower-level tests come before higher-level ones.

	* libnautilus/nautilus-string.h, libnautilus/nautilus-string.c:
	Renamed functions:
		nautilus_has_prefix -> nautilus_str_has_prefix
		nautilus_strdup_prefix -> nautilus_str_get_prefix
		nautilus_has_suffix -> nautilus_str_has_suffix
		nautilus_strstrip -> nautilus_str_strip_chr
		nautilus_string_to_int -> nautilus_str_to_int
		nautilus_eat_string_to_int -> nautilus_eat_str_to_int
	Changed nautilus_str_strip_chr not to modify in place.
	Added nautilus_str_strip_trailing_chr.

	* components/music/nautilus-music-view.c (is_mp3_file,
	nautilus_music_view_update_from_uri),
	libnautilus/nautilus-icon-factory.c
	(nautilus_icon_factory_get_icon_for_file, make_thumbnail_path,
	load_specific_image), libnautilus/nautilus-icons-view-icon-item.c
	(draw_mini_text), src/ntl-index-panel.c (command_button_cb,
	add_command_buttons), src/ntl-window-msgs.c
	(nautilus_window_change_location_2),
	src/file-manager-fm-directory-view-icons.c
	(fm_directory_view_icons_compute_menu_item_info),
	src/file-manager/fm-directory-view.c (compute_menu_item_info),
	src/file-manager/fm-icons-controller.c
	(fm_icons_controller_get_icon_property): Switched callers to use
	new names for string calls.

	* libnautilus/gnome-icon-container.c (destroy): Reformatting.

	* components/help/converters/gnome-info2html2/main.c (main):
	Fixed a warning.
2000-03-09 20:34:50 +00:00
John Sullivan
cb99884c95 Changed decision of when to draw mini-text on an icon to
be based on icon size rather than zoom level, so it works
        more sensibly with stretched icons.
2000-03-09 20:23:50 +00:00
John Sullivan
a589b69aed A few bug fixes and memory leak fixes. 2000-03-09 19:48:13 +00:00
Elliot Lee
f86e85ad8e Install libnautilus.h Handle mapping of special schemes (i.e. unknown to
* libnautilus/Makefile.am: Install libnautilus.h
* src/ntl-uri-map.c: Handle mapping of special schemes
(i.e. unknown to gnome-vfs). Currently just 'irc'.
2000-03-09 17:43:39 +00:00