diff options
author | Darin Adler <darin@src.gnome.org> | 2000-12-23 00:02:41 +0000 |
---|---|---|
committer | Darin Adler <darin@src.gnome.org> | 2000-12-23 00:02:41 +0000 |
commit | 6c10f8f9ec39b11991e69a671b8673a8c1922c32 (patch) | |
tree | 7f6d5e1c0411db0d154fc021e3d4b6cd77834bf0 /libnautilus-private/nautilus-file-utilities.h | |
parent | 1b76518ed6486501f25b07abfbc60e489e5345fd (diff) | |
download | nautilus-6c10f8f9ec39b11991e69a671b8673a8c1922c32.tar.gz |
reviewed by: Pavel Cisler <pavel@eazel.com>
Fixed bug 5065 (When Nautilus moves a directory it doesn't rename
the corresponding private metafile).
Fixed bug 5066 (Moving a directory doesn't update infomrration
about child directories in Nautilus).
Fixed bug 5297 (Make all (C) strings use gettext).
* libnautilus-extensions/nautilus-directory-metafile.c:
(nautilus_directory_rename_file_metadata),
(nautilus_directory_remove_file_metadata): Add check for NULL hash
table. Without this check we kept running into asserts.
* libnautilus-extensions/nautilus-directory-private.h:
* libnautilus-extensions/nautilus-directory.c:
(nautilus_directory_new): Share URI-setup code with the renaming
case.
(set_directory_uri): New function shared with new directories and
renaming.
(get_path_from_vfs_uri), (get_private_metafile_path): Utility
functions to help get local paths for private metafiles.
(change_directory_uri): Update URI for an existing
NautilusDirectory object. This handles renaming the private
metafile too.
(collect_directories_by_prefix): Function to collect affected
directories when you rename a directory.
(str_replace_prefix): Utility to replace string prefix so we can
turn old directory name into the new one.
(nautilus_directory_moved): Renamed and changed to use URIs
instead of a directory object so it can be called even when no
directory exists. Also made it collect all affected directories
and do the work with change_directory_uri on each one.
* libnautilus-extensions/nautilus-file.c: (rename_callback): Use
the new nautilus_directory_moved.
* libnautilus-extensions/nautilus-file-utilities.h:
* libnautilus-extensions/nautilus-file-utilities.c:
(nautilus_get_build_time_stamp):
* src/nautilus-about.h:
* src/nautilus-about.c: (nautilus_about_new),
(nautilus_about_draw_info):
* src/nautilus-window-manage-views.c:
(window_set_title_with_time_stamp), (update_title):
* src/nautilus-window-menus.c:
(help_menu_about_nautilus_callback):
Rename "timestamp" -> "time stamp".
* src/nautilus-window-menus.c:
(help_menu_about_nautilus_callback): Mark "(C)" string for
translation.
Diffstat (limited to 'libnautilus-private/nautilus-file-utilities.h')
-rw-r--r-- | libnautilus-private/nautilus-file-utilities.h | 77 |
1 files changed, 38 insertions, 39 deletions
diff --git a/libnautilus-private/nautilus-file-utilities.h b/libnautilus-private/nautilus-file-utilities.h index 1c6aee496..9fb67765f 100644 --- a/libnautilus-private/nautilus-file-utilities.h +++ b/libnautilus-private/nautilus-file-utilities.h @@ -38,43 +38,43 @@ typedef gboolean (* NautilusReadMoreCallback) (GnomeVFSFileSize file_size, gpointer callback_data); typedef struct NautilusReadFileHandle NautilusReadFileHandle; -char * nautilus_format_uri_for_display (const char *uri); -char * nautilus_make_uri_from_input (const char *location); -gboolean nautilus_uri_is_trash (const char *uri); -char * nautilus_make_uri_canonical (const char *uri); -gboolean nautilus_uris_match (const char *uri_1, - const char *uri_2); -char * nautilus_uri_get_basename (const char *uri); +char * nautilus_format_uri_for_display (const char *uri); +char * nautilus_make_uri_from_input (const char *location); +gboolean nautilus_uri_is_trash (const char *uri); +char * nautilus_make_uri_canonical (const char *uri); +gboolean nautilus_uris_match (const char *uri_1, + const char *uri_2); +char * nautilus_uri_get_basename (const char *uri); /* FIXME bugzilla.eazel.com 2424: * This is the same as gnome-libs g_concat_dir_and_file except * for handling path == NULL. */ -char * nautilus_make_path (const char *path, - const char *name); +char * nautilus_make_path (const char *path, + const char *name); /* These functions all return something something that needs to be * freed with g_free, is not NULL, and is guaranteed to exist. */ -char * nautilus_get_user_directory (void); -char * nautilus_get_user_main_directory (void); -char * nautilus_get_desktop_directory (void); -char * nautilus_get_pixmap_directory (void); +char * nautilus_get_user_directory (void); +char * nautilus_get_user_main_directory (void); +char * nautilus_get_desktop_directory (void); +char * nautilus_get_pixmap_directory (void); /* See if the user_main_directory exists. This should be called before * nautilus_get_user_main_directory, which creates the directory. */ -gboolean nautilus_user_main_directory_exists (void); +gboolean nautilus_user_main_directory_exists (void); /* Convenience routine to test if a string is a remote URI. */ -gboolean nautilus_is_remote_uri (const char *uri); +gboolean nautilus_is_remote_uri (const char *uri); @@ -86,45 +86,44 @@ gboolean nautilus_is_remote_uri (const char * We might not need this once we get on gnome-libs 2.0 which handles * gnome_pixmap_file better, using GNOME_PATH. */ -char * nautilus_pixmap_file (const char *partial_path); +char * nautilus_pixmap_file (const char *partial_path); /* Read an entire file at once with gnome-vfs. */ -GnomeVFSResult nautilus_read_entire_file (const char *uri, - int *file_size, - char **file_contents); -NautilusReadFileHandle *nautilus_read_entire_file_async (const char *uri, - NautilusReadFileCallback callback, - gpointer callback_data); -NautilusReadFileHandle *nautilus_read_file_async (const char *uri, - NautilusReadFileCallback callback, - NautilusReadMoreCallback read_more_callback, - gpointer callback_data); -void nautilus_read_file_cancel (NautilusReadFileHandle *handle); +GnomeVFSResult nautilus_read_entire_file (const char *uri, + int *file_size, + char **file_contents); +NautilusReadFileHandle *nautilus_read_entire_file_async (const char *uri, + NautilusReadFileCallback callback, + gpointer callback_data); +NautilusReadFileHandle *nautilus_read_file_async (const char *uri, + NautilusReadFileCallback callback, + NautilusReadMoreCallback read_more_callback, + gpointer callback_data); +void nautilus_read_file_cancel (NautilusReadFileHandle *handle); /* Convenience routine for simple file copying using text-based uris */ -GnomeVFSResult nautilus_copy_uri_simple (const char *source_uri, - const char *dest_uri); +GnomeVFSResult nautilus_copy_uri_simple (const char *source_uri, + const char *dest_uri); /* gnome-vfs cover to make a directory and parents */ -GnomeVFSResult nautilus_make_directory_and_parents (GnomeVFSURI *uri, - guint permissions); +GnomeVFSResult nautilus_make_directory_and_parents (GnomeVFSURI *uri, + guint permissions); -/* Returns the build timestamp the Nautilus binary. +/* Returns the build time stamp the Nautilus binary. * This is useful to be able to tell builds apart. - * A return value of NULL means unknown timestamp. + * A return value of NULL means unknown time stamp. */ -char * nautilus_get_build_timestamp (void); +char * nautilus_get_build_time_stamp (void); -/* Return an allocated file name that is guranteed to be unique */ -char * nautilus_unique_temporary_file_name (void); - -char * nautilus_find_file_in_gnome_path (char *file); -GList * nautilus_find_all_files_in_gnome_path (char *file); +/* Return an allocated file name that is guranteed to be unique. */ +char * nautilus_unique_temporary_file_name (void); +char * nautilus_find_file_in_gnome_path (char *file); +GList * nautilus_find_all_files_in_gnome_path (char *file); #endif /* NAUTILUS_FILE_UTILITIES_H */ |