summaryrefslogtreecommitdiff
path: root/src/dispextern.h
diff options
context:
space:
mode:
authorStefan Monnier <monnier@iro.umontreal.ca>2008-02-22 17:42:09 +0000
committerStefan Monnier <monnier@iro.umontreal.ca>2008-02-22 17:42:09 +0000
commit354884c46ee708a22b0372d2092256408b485c8d (patch)
tree03802c0c4e44d3ecd4b096cada74b8abf811ce29 /src/dispextern.h
parentc2e426903cfd93202e302471a6e1b265a08e8368 (diff)
downloademacs-354884c46ee708a22b0372d2092256408b485c8d.tar.gz
emacs-354884c46ee708a22b0372d2092256408b485c8d.tar.bz2
emacs-354884c46ee708a22b0372d2092256408b485c8d.zip
Consolidate the image_cache to the terminal struct.
* termhooks.h (P_): Remove redundant def. (struct terminal): New field `image_cache'. * frame.h (FRAME_IMAGE_CACHE): New macro. Use it everywhere in place of FRAME_X_IMAGE_CACHE. * xterm.h (struct x_display_info): Remove image_cache field. (FRAME_X_IMAGE_CACHE): Remove. Use FRAME_IMAGE_CACHE instead. * w32term.h (struct w32_display_info): Remove image_cache field. (FRAME_X_IMAGE_CACHE): Remove. Use FRAME_IMAGE_CACHE instead. * macterm.h (struct mac_display_info): Remove image_cache field. (FRAME_X_IMAGE_CACHE): Remove. Use FRAME_IMAGE_CACHE instead. * xterm.c (x_term_init): * w32term.c (w32_term_init): * macterm.c (mac_term_init): Set the image_cache in the terminal. * dispextern.h (clear_image_cache, forall_images_in_image_cache): Remove declarations. (clear_image_caches, mark_image_cache): New declarations. * xfaces.c (clear_face_cache): * xdisp.c (redisplay_internal): Use clear_image_caches. * image.c (clear_image_cache): Don't check that a frame is on a window-system before checking if it shares the same cache. (clear_image_caches): New function. (Fclear_image_cache): Use it. (mark_image): Move from allo.c. (mark_image_cache): Move from alloc.c and forall_images_in_image_cache. * alloc.c (mark_image, mark_image_cache): Move to image.c. (mark_object): Don't call mark_image_cache for frames. (mark_terminals): Call mark_image_cache.
Diffstat (limited to 'src/dispextern.h')
-rw-r--r--src/dispextern.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/dispextern.h b/src/dispextern.h
index daca52590b0..9e0e160c5bb 100644
--- a/src/dispextern.h
+++ b/src/dispextern.h
@@ -2547,8 +2547,8 @@ struct image_cache
no image with that id exists. */
#define IMAGE_FROM_ID(F, ID) \
- (((ID) >= 0 && (ID) < (FRAME_X_IMAGE_CACHE (F)->used)) \
- ? FRAME_X_IMAGE_CACHE (F)->images[ID] \
+ (((ID) >= 0 && (ID) < (FRAME_IMAGE_CACHE (F)->used)) \
+ ? FRAME_IMAGE_CACHE (F)->images[ID] \
: NULL)
/* Size of bucket vector of image caches. Should be prime. */
@@ -2818,9 +2818,8 @@ extern Lisp_Object x_find_image_file P_ ((Lisp_Object));
void x_kill_gs_process P_ ((Pixmap, struct frame *));
struct image_cache *make_image_cache P_ ((void));
void free_image_cache P_ ((struct frame *));
-void clear_image_cache P_ ((struct frame *, int));
-void forall_images_in_image_cache P_ ((struct frame *,
- void (*) P_ ((struct image *))));
+void clear_image_caches P_ ((int));
+void mark_image_cache P_ ((struct image_cache *));
int valid_image_p P_ ((Lisp_Object));
void prepare_image_for_display P_ ((struct frame *, struct image *));
int lookup_image P_ ((struct frame *, Lisp_Object));