Commit bf72a34c authored by Darin Adler's avatar Darin Adler

Remove eel_ prefix from name. (background_get_desktop_background_window):

	* libnautilus-private/nautilus-directory-background.c:
	(background_is_desktop): Remove eel_ prefix from name.
	(background_get_desktop_background_window): Remove eel_ prefix
	from name.

	* libnautilus-private/nautilus-icon-factory.c:
	(should_display_image_file_as_itself),
	(nautilus_icon_factory_get_icon_for_file), (load_icon_from_path):
	* libnautilus-private/nautilus-thumbnails.h:
	* libnautilus-private/nautilus-thumbnails.c: (make_thumbnail_uri),
	(nautilus_thumbnail_has_invalid_thumbnail),
	(nautilus_get_thumbnail_uri),
	(nautilus_update_thumbnail_file_renamed),
	(nautilus_remove_thumbnail_for_file), (check_for_thumbnails),
	(make_thumbnails), (nautilus_thumbnail_load_framed_image):
	Remove anti-aliased parameter from most functions, since the
	thumbnails are now the same either way.

	* THANKS:
	* check-THANKS.pl:
	Some more THANKS updates.

	* RPMs-README: No need for this any more.
parent de818215
2001-07-24 Darin Adler <darin@bentspoon.com>
* libnautilus-private/nautilus-directory-background.c:
(background_is_desktop): Remove eel_ prefix from name.
(background_get_desktop_background_window): Remove eel_ prefix
from name.
* libnautilus-private/nautilus-icon-factory.c:
(should_display_image_file_as_itself),
(nautilus_icon_factory_get_icon_for_file), (load_icon_from_path):
* libnautilus-private/nautilus-thumbnails.h:
* libnautilus-private/nautilus-thumbnails.c: (make_thumbnail_uri),
(nautilus_thumbnail_has_invalid_thumbnail),
(nautilus_get_thumbnail_uri),
(nautilus_update_thumbnail_file_renamed),
(nautilus_remove_thumbnail_for_file), (check_for_thumbnails),
(make_thumbnails), (nautilus_thumbnail_load_framed_image):
Remove anti-aliased parameter from most functions, since the
thumbnails are now the same either way.
* THANKS:
* check-THANKS.pl:
Some more THANKS updates.
* RPMs-README: No need for this any more.
2001-07-24 Jens Finke <jens@gnome.org>
* components/news/news_channels.xml: Updated KDE rdf location.
......
--------------------------------------------------------------------------
- Building Nautilus RPMs -
--------------------------------------------------------------------------
Building Nautilus RPMs from CVS HEAD usually works, since Eazel's build
engineer tests the RPM building process regularly. We encourage people to
test out RPM builds, and report bugs about them to the Nautilus mailing list:
<nautilus-list@lists.eazel.com>.
However, we would prefer if no one distributed RPMs created from CVS versions
of the source code: Eazel will make RPMs for releases of Nautilus, so that
people can use it without going through the pain of setting up a build
system, but we'd be happier if there weren't RPMs out there for other
non-released versions.
If, despite this, you decide to distribute your own RPMs, please contact
the Nautilus maintainer, Darin Adler <darin@eazel.com>, and let him know.
The Nautilus team would like to thank the following contributors:
Alex Larsson <alexl@redhat.com> - faster thumbnailing for JPEGs, bug fixes
Anders Carlsson <andersca@gnu.org> - background drawing optimizations
Anders Carlsson <andersca@gnome.org> - background drawing optimizations
Arik Devens <arik@eazel.com> - bug fixes
Bart Decrem <bart@eazel.com> - fixes to default news channels, gathering feedback, founding Eazel :-)
Brian Frank <bfrank@eazel.com> - fixes to default bookmarks, product marketing
......@@ -17,6 +17,7 @@ Gregory S. Hayes <ghayes@syncomm.org> - bug fixes
Havoc Pennington <hp@redhat.com> - various contributions
JP Rosevear <jpr@arcavia.com> - bug fixes
Jason Leach <jasonleach@usa.net> - Solaris fix
Jens Finke <jens@gnome.org> - URL fix
Jim Garrison <garrison@users.sourceforge.net> - bug fixes
Joe Shaw <joe@ximian.com> - installer code, bug fixes
John Fleck <jfleck@inkstain.net> - help browser work
......
......@@ -57,7 +57,8 @@ my %email_map =
(
'alla@lysator.liu.se' => 'alexl@redhat.com',
'almer1@dds.nl' => 'almer@gnome.org',
'andersca@codefactory.se' => 'andersca@gnu.org',
'andersca@codefactory.se' => 'andersca@gnome.org',
'andersca@gnu.org' => 'andersca@gnome.org',
'andy@eazel.com' => 'andy@differnet.com',
'arik@gnome.org' => 'arik@eazel.com',
'at@ue-spacy.com' => 'tagoh@gnome.gr.jp',
......
......@@ -114,7 +114,7 @@ nautilus_connect_desktop_background_to_file_metadata (NautilusIconContainer *ico
}
static gboolean
eel_background_is_desktop (EelBackground *background)
background_is_desktop (EelBackground *background)
{
/* == works because we're carful to always use the same string.
*/
......@@ -131,7 +131,7 @@ static const char *nautilus_file_background_peek_theme_source (EelBackground *ba
}
static GdkWindow *
eel_background_get_desktop_background_window (EelBackground *background)
background_get_desktop_background_window (EelBackground *background)
{
gpointer layout;
......@@ -672,7 +672,7 @@ image_loading_done_callback (EelBackground *background, gboolean successful_load
set_root_pixmap (pixmap);
background_window = eel_background_get_desktop_background_window (background);
background_window = background_get_desktop_background_window (background);
if (background_window != NULL) {
gdk_window_set_back_pixmap (background_window, pixmap, FALSE);
}
......@@ -769,7 +769,7 @@ background_changed_callback (EelBackground *background,
color = eel_background_get_color (background);
image = eel_background_get_image_uri (background);
if (eel_background_is_desktop (background)) {
if (background_is_desktop (background)) {
nautilus_file_background_write_desktop_settings (color, image, eel_background_get_image_placement (background));
} else {
/* Block the other handler while we are writing metadata so it doesn't
......@@ -798,7 +798,7 @@ background_changed_callback (EelBackground *background,
g_free (color);
g_free (image);
if (eel_background_is_desktop (background)) {
if (background_is_desktop (background)) {
nautilus_file_update_desktop_pixmaps (background);
}
}
......@@ -816,7 +816,7 @@ initialize_background_from_settings (NautilusFile *file,
g_assert (gtk_object_get_data (GTK_OBJECT (background), "eel_background_file")
== file);
if (eel_background_is_desktop (background)) {
if (background_is_desktop (background)) {
nautilus_file_background_read_desktop_settings (&color, &image, &placement);
} else {
color = nautilus_file_get_metadata (file,
......@@ -862,7 +862,7 @@ saved_settings_changed_callback (NautilusFile *file,
{
initialize_background_from_settings (file, background);
if (eel_background_is_desktop (background)) {
if (background_is_desktop (background)) {
nautilus_file_update_desktop_pixmaps (background);
}
}
......@@ -886,7 +886,7 @@ static void
background_reset_callback (EelBackground *background,
NautilusFile *file)
{
if (eel_background_is_desktop (background)) {
if (background_is_desktop (background)) {
nautilus_file_background_write_desktop_default_settings ();
} else {
/* Block the other handler while we are writing metadata so it doesn't
......
......@@ -1422,7 +1422,7 @@ should_display_image_file_as_itself (NautilusFile *file, gboolean optimized_for_
/* see if there's a proxy thumbnail to indicate that thumbnailing
* failed, in which case we shouldn't use the thumbnail.
*/
if (nautilus_thumbnail_has_invalid_thumbnail (file, optimized_for_aa)) {
if (nautilus_thumbnail_has_invalid_thumbnail (file)) {
return FALSE;
}
......@@ -1529,7 +1529,7 @@ nautilus_icon_factory_get_icon_for_file (NautilusFile *file, const char *modifie
uri = nautilus_file_get_uri (file);
} else if (strstr (file_uri, "/.thumbnails/") == NULL
&& file_size < cached_thumbnail_limit) {
uri = nautilus_get_thumbnail_uri (file, TRUE);
uri = nautilus_get_thumbnail_uri (file);
if (uri == NULL) {
icon_name = g_strdup (ICON_NAME_THUMBNAIL_LOADING);
}
......@@ -1893,7 +1893,7 @@ load_icon_from_path (const char *path,
}
/* if it's a thumbnail, frame it if necessary */
if (strstr (path, ".thumbnails") != NULL) {
if (strstr (path, "/.thumbnails/") != NULL) {
return nautilus_thumbnail_load_framed_image (path, optimized_for_aa);
}
......
......@@ -152,7 +152,7 @@ obfuscate_password (const char *escaped_uri)
static char *
make_thumbnail_uri (const char *image_uri, gboolean directory_only, gboolean use_local_directory,
gboolean anti_aliased, gboolean create_parents_if_needed)
gboolean create_parents_if_needed)
{
char *thumbnail_uri, *thumbnail_path;
char *directory_name = g_strdup (image_uri);
......@@ -253,7 +253,6 @@ first_file_more_recent (const char* file_uri, const char* other_file_uri)
typedef struct {
char *thumbnail_uri;
gboolean is_local;
gboolean anti_aliased;
pid_t thumbnail_task;
} NautilusThumbnailInfo;
......@@ -289,8 +288,8 @@ make_invalid_thumbnail_uri (const char *thumbnail_uri)
* file, which indicates that a previous thumbnailing attempt failed and
* we should use the mime-type icon instead
*/
gboolean nautilus_thumbnail_has_invalid_thumbnail (NautilusFile *file,
gboolean anti_aliased)
gboolean
nautilus_thumbnail_has_invalid_thumbnail (NautilusFile *file)
{
char *file_uri, *thumbnail_uri, *invalid_thumbnail_uri;
gboolean is_invalid;
......@@ -298,7 +297,7 @@ gboolean nautilus_thumbnail_has_invalid_thumbnail (NautilusFile *file,
file_uri = nautilus_file_get_uri (file);
thumbnail_uri = make_thumbnail_uri (file_uri, FALSE, uri_is_local (file_uri), anti_aliased, TRUE);
thumbnail_uri = make_thumbnail_uri (file_uri, FALSE, uri_is_local (file_uri), TRUE);
invalid_thumbnail_uri = make_invalid_thumbnail_uri (thumbnail_uri);
is_invalid = vfs_file_exists (invalid_thumbnail_uri);
......@@ -316,7 +315,7 @@ gboolean nautilus_thumbnail_has_invalid_thumbnail (NautilusFile *file,
*/
char *
nautilus_get_thumbnail_uri (NautilusFile *file, gboolean anti_aliased)
nautilus_get_thumbnail_uri (NautilusFile *file)
{
GnomeVFSResult result;
char *thumbnail_uri;
......@@ -328,7 +327,7 @@ nautilus_get_thumbnail_uri (NautilusFile *file, gboolean anti_aliased)
file_uri = nautilus_file_get_uri (file);
thumbnail_uri = make_thumbnail_uri (file_uri, FALSE, uri_is_local (file_uri), anti_aliased, TRUE);
thumbnail_uri = make_thumbnail_uri (file_uri, FALSE, uri_is_local (file_uri), TRUE);
/* if the thumbnail file already exists locally, simply return the uri */
......@@ -354,7 +353,7 @@ nautilus_get_thumbnail_uri (NautilusFile *file, gboolean anti_aliased)
/* now try it globally */
if (!remake_thumbnail) {
g_free (thumbnail_uri);
thumbnail_uri = make_thumbnail_uri (file_uri, FALSE, FALSE, anti_aliased, TRUE);
thumbnail_uri = make_thumbnail_uri (file_uri, FALSE, FALSE, TRUE);
/* if the thumbnail file already exists in the common area, return that uri, */
/* the uri is guaranteed to be local */
......@@ -379,7 +378,7 @@ nautilus_get_thumbnail_uri (NautilusFile *file, gboolean anti_aliased)
/* make the thumbnail directory if necessary, at first try it locally */
g_free (thumbnail_uri);
local_flag = TRUE;
thumbnail_uri = make_thumbnail_uri (file_uri, TRUE, local_flag, anti_aliased, TRUE);
thumbnail_uri = make_thumbnail_uri (file_uri, TRUE, local_flag, TRUE);
/* FIXME bugzilla.eazel.com 3137: more potentially losing
synch I/O - this could be remote */
......@@ -398,7 +397,7 @@ nautilus_get_thumbnail_uri (NautilusFile *file, gboolean anti_aliased)
if (!can_write || (result != GNOME_VFS_OK && result != GNOME_VFS_ERROR_FILE_EXISTS)) {
g_free (thumbnail_uri);
local_flag = FALSE;
thumbnail_uri = make_thumbnail_uri (file_uri, TRUE, local_flag, anti_aliased, TRUE);
thumbnail_uri = make_thumbnail_uri (file_uri, TRUE, local_flag, TRUE);
/* this is guaranteed to be local, so synch I/O can be tolerated here */
result = gnome_vfs_make_directory (thumbnail_uri, THUMBNAIL_DIR_PERMISSIONS);
}
......@@ -411,7 +410,6 @@ nautilus_get_thumbnail_uri (NautilusFile *file, gboolean anti_aliased)
NautilusThumbnailInfo *info = g_new0 (NautilusThumbnailInfo, 1);
info->thumbnail_uri = file_uri;
info->is_local = local_flag;
info->anti_aliased = anti_aliased;
if (g_list_find_custom (thumbnails, info, compare_thumbnail_info) == NULL) {
thumbnails = g_list_append (thumbnails, info);
......@@ -429,18 +427,17 @@ nautilus_get_thumbnail_uri (NautilusFile *file, gboolean anti_aliased)
return NULL;
}
static void
nautilus_update_thumbnail_file_renamed_one (const char *old_file_uri, const char *new_file_uri,
gboolean anti_aliased)
void
nautilus_update_thumbnail_file_renamed (const char *old_file_uri, const char *new_file_uri)
{
gboolean is_local;
char *old_thumbnail_uri, *new_thumbnail_uri;
is_local = uri_is_local (old_file_uri);
old_thumbnail_uri = make_thumbnail_uri (old_file_uri, FALSE, is_local, anti_aliased, FALSE);
old_thumbnail_uri = make_thumbnail_uri (old_file_uri, FALSE, is_local, FALSE);
if (old_thumbnail_uri != NULL && vfs_file_exists (old_thumbnail_uri)) {
new_thumbnail_uri = make_thumbnail_uri (new_file_uri, FALSE, is_local, anti_aliased, FALSE);
new_thumbnail_uri = make_thumbnail_uri (new_file_uri, FALSE, is_local, FALSE);
g_assert (new_thumbnail_uri != NULL);
......@@ -452,21 +449,12 @@ nautilus_update_thumbnail_file_renamed_one (const char *old_file_uri, const char
g_free (old_thumbnail_uri);
}
/* update the thumbnail after the thumbnailed file got renamed */
void
nautilus_update_thumbnail_file_renamed (const char *old_file_uri, const char *new_file_uri)
{
/* rename both the AA and non-AA thumbnails, if they exist */
nautilus_update_thumbnail_file_renamed_one (old_file_uri, new_file_uri, FALSE);
nautilus_update_thumbnail_file_renamed_one (old_file_uri, new_file_uri, TRUE);
}
static void
nautilus_remove_thumbnail_for_file_one (const char *old_file_uri, gboolean anti_aliased)
nautilus_remove_thumbnail_for_file (const char *old_file_uri)
{
char *thumbnail_uri;
thumbnail_uri = make_thumbnail_uri (old_file_uri, FALSE, uri_is_local (old_file_uri), anti_aliased, FALSE);
thumbnail_uri = make_thumbnail_uri (old_file_uri, FALSE, uri_is_local (old_file_uri), FALSE);
if (thumbnail_uri != NULL && vfs_file_exists (thumbnail_uri)) {
gnome_vfs_unlink (thumbnail_uri);
}
......@@ -474,15 +462,6 @@ nautilus_remove_thumbnail_for_file_one (const char *old_file_uri, gboolean anti_
g_free (thumbnail_uri);
}
/* remove the thumbnail after the thumbnailed file got deleted */
void
nautilus_remove_thumbnail_for_file (const char *old_file_uri)
{
/* remove both the AA and non-AA thumbnails, if they exist */
nautilus_remove_thumbnail_for_file_one (old_file_uri, FALSE);
nautilus_remove_thumbnail_for_file_one (old_file_uri, TRUE);
}
/* check_for_thumbnails is a utility that checks to see if the current thumbnail task has terminated.
If it has, remove the thumbnail info from the queue and return TRUE; if it's still in progress, return FALSE.
*/
......@@ -507,8 +486,7 @@ check_for_thumbnails (void)
/* the thumbnail task has completed, so update the current entry from the list */
file = nautilus_file_get (info->thumbnail_uri);
current_thumbnail = make_thumbnail_uri (info->thumbnail_uri, FALSE, info->is_local,
info->anti_aliased, TRUE);
current_thumbnail = make_thumbnail_uri (info->thumbnail_uri, FALSE, info->is_local, TRUE);
/* if a thumbnail wasn't successfully made, create a placeholder to flag that we tried */
need_update = TRUE;
......@@ -576,8 +554,7 @@ make_thumbnails (gpointer data)
/* First, compute the path name of the target thumbnail */
g_free (new_thumbnail_uri);
new_thumbnail_uri = make_thumbnail_uri (info->thumbnail_uri, FALSE, info->is_local,
info->anti_aliased, TRUE);
new_thumbnail_uri = make_thumbnail_uri (info->thumbnail_uri, FALSE, info->is_local, TRUE);
/* fork a task to make the thumbnail, using gdk-pixbuf to do the scaling */
if (!(info->thumbnail_task = fork())) {
......@@ -711,7 +688,8 @@ pixbuf_is_framed (GdkPixbuf *pixbuf)
/* routine to load an image from the passed-in path, and then embed it in
* a frame if necessary
*/
GdkPixbuf * nautilus_thumbnail_load_framed_image (const char *path, gboolean anti_aliased)
GdkPixbuf *
nautilus_thumbnail_load_framed_image (const char *path, gboolean anti_aliased_frame)
{
GdkPixbuf *pixbuf, *framed_image, *thumbnail_image_frame;
char *frame_offset_str;
......@@ -724,7 +702,7 @@ GdkPixbuf * nautilus_thumbnail_load_framed_image (const char *path, gboolean ant
/* the pixbuf isn't framed (i.e., it was made with newer code), so we must embed it in it's frame now */
thumbnail_image_frame = nautilus_icon_factory_get_thumbnail_frame (anti_aliased);
thumbnail_image_frame = nautilus_icon_factory_get_thumbnail_frame (anti_aliased_frame);
frame_offset_str = nautilus_theme_get_theme_data ("thumbnails", "FRAME_OFFSETS");
if (frame_offset_str != NULL) {
......@@ -743,4 +721,3 @@ GdkPixbuf * nautilus_thumbnail_load_framed_image (const char *path, gboolean ant
gdk_pixbuf_unref (pixbuf);
return framed_image;
}
......@@ -29,15 +29,12 @@
#include <gdk-pixbuf/gdk-pixbuf.h>
/* Returns NULL if there's no thumbnail yet. */
char *nautilus_get_thumbnail_uri (NautilusFile *file, gboolean anti_aliased);
gboolean nautilus_thumbnail_has_invalid_thumbnail (NautilusFile *file, gboolean anti_aliased);
GdkPixbuf * nautilus_thumbnail_load_framed_image (const char *path, gboolean anti_aliased);
void nautilus_update_thumbnail_file_renamed (const char *old_file_uri,
const char *new_file_uri);
void nautilus_remove_thumbnail_for_file (const char *old_file_uri);
char * nautilus_get_thumbnail_uri (NautilusFile *file);
gboolean nautilus_thumbnail_has_invalid_thumbnail (NautilusFile *file);
GdkPixbuf *nautilus_thumbnail_load_framed_image (const char *path,
gboolean anti_alias_frame_edges);
void nautilus_update_thumbnail_file_renamed (const char *old_file_uri,
const char *new_file_uri);
void nautilus_remove_thumbnail_for_file (const char *old_file_uri);
#endif /* NAUTILUS_THUMBNAILS_H */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment