* xfns.c (x_real_positions): int ign => unsigned int.

(xg_set_icon_from_xpm_data): Remove unused variable err.
(x_set_name_internal, Fx_create_frame, xg_set_icon): Add cast
to remove compiler warning.
(compute_tip_xy): Put tip above pointer if it doesn't fit below.
This commit is contained in:
Jan Djärv 2005-12-02 14:55:14 +00:00
parent 0a79da1b5d
commit 47c53789fd

View file

@ -608,7 +608,7 @@ x_real_positions (f, xptr, yptr)
if (! had_errors)
{
int ign;
unsigned int ign;
Window child, rootw;
/* Get the real coordinates for the WM window upper left corner */
@ -794,9 +794,7 @@ xg_set_icon (f, file)
{
GdkPixbuf *pixbuf;
GError *err = NULL;
char *filename;
filename = SDATA (found);
char *filename = (char *) SDATA (found);
BLOCK_INPUT;
pixbuf = gdk_pixbuf_new_from_file (filename, &err);
@ -825,17 +823,12 @@ xg_set_icon_from_xpm_data (f, data)
char **data;
{
int result = 0;
GError *err = NULL;
GdkPixbuf *pixbuf = gdk_pixbuf_new_from_xpm_data (data);
GdkPixbuf *pixbuf = gdk_pixbuf_new_from_xpm_data ((const char **) data);
if (!pixbuf)
{
g_error_free (err);
return 0;
}
return 0;
gtk_window_set_icon (GTK_WINDOW (FRAME_GTK_OUTER_WIDGET (f)),
pixbuf);
gtk_window_set_icon (GTK_WINDOW (FRAME_GTK_OUTER_WIDGET (f)), pixbuf);
g_object_unref (pixbuf);
return 1;
}
@ -1649,7 +1642,7 @@ x_set_name_internal (f, name)
#ifdef USE_GTK
gtk_window_set_title (GTK_WINDOW (FRAME_GTK_OUTER_WIDGET (f)),
SDATA (ENCODE_UTF_8 (name)));
(char *) SDATA (ENCODE_UTF_8 (name)));
#else /* not USE_GTK */
XSetWMName (FRAME_X_DISPLAY (f), FRAME_OUTER_WINDOW (f), &text);
#endif /* not USE_GTK */
@ -3376,7 +3369,7 @@ This function is an internal primitive--use `make-frame' instead. */)
FRAME_OUTER_WINDOW (f),
dpyinfo->Xatom_wm_client_leader,
XA_WINDOW, 32, PropModeReplace,
(char *) &dpyinfo->client_leader_window, 1);
(unsigned char *) &dpyinfo->client_leader_window, 1);
UNBLOCK_INPUT;
}
@ -4942,6 +4935,9 @@ compute_tip_xy (f, parms, dx, dy, width, height, root_x, root_y)
*root_y = XINT (top);
else if (*root_y + XINT (dy) - height < 0)
*root_y -= XINT (dy);
else if (*root_y + XINT (dy) >= FRAME_X_DISPLAY_INFO (f)->height)
/* Put tip above the pointer. */
*root_y -= XINT (dy);
else
{
*root_y -= height;