From dee186b61d9f2528ed1f2125035dd7e5e5a12f2a Mon Sep 17 00:00:00 2001 From: Jan D Date: Fri, 22 Oct 2010 07:49:47 +0200 Subject: [PATCH] Fix compilation with Motif (Bug#7263). * src/xfns.c: Include Xm/TextF and Xm/List. (file_dialog_cb, file_dialog_unmap_cb, clean_up_file_dialog): Make ANSI prototypes. * src/xmenu.c: Revert 2010-07-27 change: lwlib.h is needed for MOTIF (Bug#7263). * src/xrdb.c: Include keyboard.h for MOTIF. --- src/ChangeLog | 11 +++++++++++ src/xfns.c | 13 +++++-------- src/xmenu.c | 1 + src/xrdb.c | 5 +++++ 4 files changed, 22 insertions(+), 8 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 1b1de29a0f1..05a0d442149 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,14 @@ +2010-10-22 Jan Djärv + + * xrdb.c: Include keyboard.h for MOTIF. + + * xmenu.c: Revert 2010-07-27 change: lwlib.h is needed for + MOTIF (Bug#7263). + + * xfns.c: Include Xm/TextF and Xm/List. + (file_dialog_cb, file_dialog_unmap_cb, clean_up_file_dialog): Make + ANSI prototypes. + 2010-10-22 Glenn Morris * Makefile.in (SOME_MACHINE_LISP): Add w32-vars. diff --git a/src/xfns.c b/src/xfns.c index cb6733e8fa1..b2f8222c6ec 100644 --- a/src/xfns.c +++ b/src/xfns.c @@ -99,6 +99,8 @@ along with GNU Emacs. If not, see . */ #include #include #include +#include +#include #endif #ifdef USE_LUCID @@ -5299,9 +5301,7 @@ DEFUN ("x-uses-old-gtk-dialog", Fx_uses_old_gtk_dialog, /* Callback for "OK" and "Cancel" on file selection dialog. */ static void -file_dialog_cb (widget, client_data, call_data) - Widget widget; - XtPointer call_data, client_data; +file_dialog_cb (Widget widget, XtPointer client_data, XtPointer call_data) { int *result = (int *) client_data; XmAnyCallbackStruct *cb = (XmAnyCallbackStruct *) call_data; @@ -5315,17 +5315,14 @@ file_dialog_cb (widget, client_data, call_data) in this case. */ static void -file_dialog_unmap_cb (widget, client_data, call_data) - Widget widget; - XtPointer call_data, client_data; +file_dialog_unmap_cb (Widget widget, XtPointer client_data, XtPointer call_data) { int *result = (int *) client_data; *result = XmCR_CANCEL; } static Lisp_Object -clean_up_file_dialog (arg) - Lisp_Object arg; +clean_up_file_dialog (Lisp_Object arg) { struct Lisp_Save_Value *p = XSAVE_VALUE (arg); Widget dialog = (Widget) p->pointer; diff --git a/src/xmenu.c b/src/xmenu.c index 68b442388a5..60b1c2b4595 100644 --- a/src/xmenu.c +++ b/src/xmenu.c @@ -89,6 +89,7 @@ along with GNU Emacs. If not, see . */ #include #endif /* HAVE_XAW3D */ #endif /* USE_LUCID */ +#include "../lwlib/lwlib.h" #else /* not USE_X_TOOLKIT */ #ifndef USE_GTK #include "../oldXMenu/XMenu.h" diff --git a/src/xrdb.c b/src/xrdb.c index d2898e1d8f8..90a85e287bb 100644 --- a/src/xrdb.c +++ b/src/xrdb.c @@ -48,6 +48,11 @@ along with GNU Emacs. If not, see . */ #include "lisp.h" +#ifdef USE_MOTIF +/* For Vdouble_click_time. */ +#include "keyboard.h" +#endif + extern char *getenv (const char *); extern struct passwd *getpwuid (uid_t); -- 2.39.5