APPROVE COMMIT 21.5
src/ChangeLog addition:
2005-11-22 Malcolm Purvis <malcolmp(a)xemacs.org>
* frame-gtk.c (gtk_internal_frame_property_p):
* glyphs-gtk.c (image_instance_convert_to_pointer):
* glyphs-gtk.c (gtk_xpm_instantiate):
* glyphs-gtk.h (IMAGE_INSTANCE_GTK_MASK):
* gtk-xemacs.c (gtk_xemacs_expose):
* redisplay-gtk.c (gtk_output_vertical_divider):
Fix compilation errors and warnings that have appeared over the
last few months.
xemacs-gtk-warnings source patch:
Diff command: cvs -q diff -u
Files affected: src/redisplay-gtk.c src/gtk-xemacs.c src/glyphs-gtk.h src/glyphs-gtk.c
src/frame-gtk.c
Index: src/frame-gtk.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/frame-gtk.c,v
retrieving revision 1.20
diff -u -r1.20 frame-gtk.c
--- src/frame-gtk.c 2005/01/24 23:33:56 1.20
+++ src/frame-gtk.c 2005/11/22 11:14:23
@@ -265,7 +265,7 @@
}
static int
-gtk_internal_frame_property_p (struct frame *f, Lisp_Object property)
+gtk_internal_frame_property_p (struct frame *UNUSED(f), Lisp_Object property)
{
return EQ (property, Qleft)
|| EQ (property, Qtop)
Index: src/glyphs-gtk.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/glyphs-gtk.c,v
retrieving revision 1.31
diff -u -r1.31 glyphs-gtk.c
--- src/glyphs-gtk.c 2005/09/27 05:48:26 1.31
+++ src/glyphs-gtk.c 2005/11/22 11:14:25
@@ -686,8 +686,8 @@
Lisp_Object pointer_bg)
{
Lisp_Object device = IMAGE_INSTANCE_DEVICE (ii);
- GdkPixmap *pixmap = IMAGE_INSTANCE_X_PIXMAP (ii);
- GdkPixmap *mask = (GdkPixmap *) IMAGE_INSTANCE_PIXMAP_MASK (ii);
+ GdkPixmap *pixmap = IMAGE_INSTANCE_GTK_PIXMAP (ii);
+ GdkPixmap *mask = (GdkPixmap *) IMAGE_INSTANCE_GTK_MASK (ii);
GdkColor fg, bg;
int xhot = 0, yhot = 0;
int w, h;
@@ -1310,7 +1310,7 @@
gdk_window_get_geometry (pixmap, NULL, NULL, &w, &h, &depth);
IMAGE_INSTANCE_GTK_PIXMAP (ii) = pixmap;
- IMAGE_INSTANCE_PIXMAP_MASK (ii) = (void*)mask;
+ IMAGE_INSTANCE_PIXMAP_MASK (ii) = mask;
IMAGE_INSTANCE_GTK_COLORMAP (ii) = cmap;
IMAGE_INSTANCE_GTK_PIXELS (ii) = 0;
IMAGE_INSTANCE_GTK_NPIXELS (ii) = 0;
@@ -1329,11 +1329,12 @@
break;
case IMAGE_POINTER:
- if (xpmattrs.valuemask & XpmHotspot)
- IMAGE_INSTANCE_PIXMAP_HOTSPOT_X (ii) = make_int (xpmattrs.x_hotspot);
- if (xpmattrs.valuemask & XpmHotspot)
- IMAGE_INSTANCE_PIXMAP_HOTSPOT_Y (ii) = make_int (xpmattrs.y_hotspot);
-
+ /* #### Gtk does not give us access to the hotspots of a pixmap */
+
+ IMAGE_INSTANCE_PIXMAP_HOTSPOT_X (ii) = 1;
+ IMAGE_INSTANCE_PIXMAP_HOTSPOT_Y (ii) = 1;
+
+
image_instance_convert_to_pointer (ii, instantiator, pointer_fg,
pointer_bg);
break;
Index: src/glyphs-gtk.h
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/glyphs-gtk.h,v
retrieving revision 1.3
diff -u -r1.3 glyphs-gtk.h
--- src/glyphs-gtk.h 2004/05/15 07:43:09 1.3
+++ src/glyphs-gtk.h 2005/11/22 11:14:26
@@ -86,7 +86,7 @@
(GTK_IMAGE_INSTANCE_DATA (i)->pixmaps[slice])
#define IMAGE_INSTANCE_GTK_PIXMAP_SLICES(i) \
(GTK_IMAGE_INSTANCE_DATA (i)->pixmaps)
-#define IMAGE_INSTANCE_GTK_MASK(i) (GdkPixmap*)(IMAGE_INSTANCE_PIXMAP_MASK (i))
+#define IMAGE_INSTANCE_GTK_MASK(i) ((GdkPixmap*)(IMAGE_INSTANCE_PIXMAP_MASK (i)))
#define IMAGE_INSTANCE_GTK_CURSOR(i) (GTK_IMAGE_INSTANCE_DATA (i)->cursor)
#define IMAGE_INSTANCE_GTK_COLORMAP(i) (GTK_IMAGE_INSTANCE_DATA (i)->colormap)
#define IMAGE_INSTANCE_GTK_PIXELS(i) (GTK_IMAGE_INSTANCE_DATA (i)->pixels)
Index: src/gtk-xemacs.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/gtk-xemacs.c,v
retrieving revision 1.14
diff -u -r1.14 gtk-xemacs.c
--- src/gtk-xemacs.c 2004/10/16 13:08:58 1.14
+++ src/gtk-xemacs.c 2005/11/22 11:14:26
@@ -410,6 +410,8 @@
redisplay_redraw_exposed_area (f, a->x, a->y, a->width, a->height);
return (TRUE);
}
+
+ return FALSE;
}
Lisp_Object
Index: src/redisplay-gtk.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/redisplay-gtk.c,v
retrieving revision 1.17
diff -u -r1.17 redisplay-gtk.c
--- src/redisplay-gtk.c 2005/01/24 23:34:06 1.17
+++ src/redisplay-gtk.c 2005/11/22 11:14:28
@@ -1176,7 +1176,7 @@
Draw a vertical divider down the right side of the given window.
****************************************************************************/
static void
-gtk_output_vertical_divider (struct window *w, int clear)
+gtk_output_vertical_divider (struct window *w, int UNUSED(clear))
{
struct frame *f = XFRAME (w->frame);
struct device *d = XDEVICE (f->device);
--
Malcolm Purvis <malcolmp(a)xemacs.org>
Show replies by date