noinst_LIBRARIES=libsxeevents.a
-#
+#
# Help the SXEmacs developers get nice post-processed source files
## Create preprocessor output (debugging purposes only)
Author: Sebastian Freundt <hroptatyr@sxemacs.org>
* This file is part of SXEmacs.
- *
+ *
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
Author: Sebastian Freundt <hroptatyr@sxemacs.org>
* This file is part of SXEmacs.
- *
+ *
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
every time the file descriptor becomes
active, so the filter function forces this
by returning 0. Emacs must not interpret
- this as a closed pipe.
+ this as a closed pipe.
We don't do ToolTalk anymore, but come
back and revisit this for D-Bus */
-- nil (there is no binding)
-- a keymap (part of a command has been specified)
-- a command (anything that satisfies `commandp'; this includes
- some symbols, lists, subrs, strings, vectors, and
+ some symbols, lists, subrs, strings, vectors, and
compiled-function objects)
*/
static Lisp_Object
-- nil (there is no binding)
-- a keymap (part of a command has been specified)
-- a command (anything that satisfies `commandp'; this includes
- some symbols, lists, subrs, strings, vectors, and
+ some symbols, lists, subrs, strings, vectors, and
compiled-function objects)
*/
static Lisp_Object
void
asyneq_handle_non_command_event(event_queue_t eq)
{
- Lisp_Object eqev = Qnil;
+ Lisp_Object eqev = Qnil;
- WITH_DLLIST_TRAVERSE(
- eq_queue(eq),
- if (!command_event_p((Lisp_Object)dllist_item)) {
- eqev = (Lisp_Object)dllist_pop_inner(eq_queue(eq), _el);
- break;
- });
+ WITH_DLLIST_TRAVERSE(
+ eq_queue(eq),
+ if (!command_event_p((Lisp_Object)dllist_item)) {
+ eqev = (Lisp_Object)dllist_pop_inner(eq_queue(eq), _el);
+ break;
+ });
- if (!NILP(eqev)) {
- execute_internal_event(eqev);
+ if (!NILP(eqev)) {
+ execute_internal_event(eqev);
}
return;
}
*/ );
modifier_keys_are_sticky = 0;
- DEFVAR_LISP("modifier-keys-sticky-time",
+ DEFVAR_LISP("modifier-keys-sticky-time",
&Vmodifier_keys_sticky_time /*
*Modifier keys are sticky within this many milliseconds.
If you don't want modifier keys sticking to be bounded, set this to
Vmodifier_keys_sticky_time = make_int(500);
#ifdef HAVE_XIM
- DEFVAR_LISP("composed-character-default-binding",
+ DEFVAR_LISP("composed-character-default-binding",
&Vcomposed_character_default_binding /*
The default keybinding to use for key events from composed input.
Window systems frequently have ways to allow the user to compose
ommand-event) An event taken from `unread-command-event'.
event queue) An event taken from an internal queue.
- Events end up on this queue when
- `enqueue-eval-event' is called or when
- user or eval events are received while
- SXEmacs is blocking (e.g. in `sit-for',
- `sleep-for', or `accept-process-output',
- or while waiting for the reply to an
- X selection).
-
-rd-translate-table) The result of an event translated
- through keyboard-translate-table. Note
- that in this case, two events are
- printed even though only one is really
- generated.
+ Events end up on this queue when
+ `enqueue-eval-event' is called or when
+ user or eval events are received while
+ SXEmacs is blocking (e.g. in `sit-for',
+ `sleep-for', or `accept-process-output',
+ or while waiting for the reply to an
+ X selection).
+
+rd-translate-table) The result of an event translated
+ through keyboard-translate-table. Note
+ that in this case, two events are
+ printed even though only one is really
+ generated.
A faked C-g resulting when SXEmacs receives
a SIGINT (e.g. C-c was pressed in SXEmacs'
(defun test-them ()
(let ((start (current-time))
- end)
+ end)
(add-timeout 2 'testee nil)
(sit-for 5)
(add-timeout 2 'testee nil)
These work as follows:
input_wait_mask == mask of all file descriptors we select() on,
- including TTY/stream console descriptors,
+ including TTY/stream console descriptors,
process descriptors, and the signal event pipe.
Only used in event-tty.c; event-Xt.c uses
XtAppAddInput(), and the call to select() is down in
the guts of Xt.
non_fake_input_wait_mask == same as input_wait_mask but minus the
- signal event pipe. Also only used in
+ signal event pipe. Also only used in
event-tty.c.
process_only_mask == only the process descriptors.
#include "lisp.h"
#include "buffer.h"
#include "ui/console.h"
-#include "ui/TTY/console-tty.h" /* for stuff in
+#include "ui/TTY/console-tty.h" /* for stuff in
character_to_event. needs
refactoring */
#include "ui/device.h"
-#include "ui/X11/console-x.h" /* for x_event_name prototype in
+#include "ui/X11/console-x.h" /* for x_event_name prototype in
format_event_object. Needs refactoring */
#include "extents.h" /* Just for the EXTENTP abort check... */
#define INCLUDE_EVENTS_H_PRIVATE_SPHERE
break;
#ifdef EF_USE_ASYNEQ
- /* are these right here? */
+ /* are these right here? */
case eaten_myself_event:
case work_started_event:
case work_finished_event:
not occurring until the next event occurs.
handle_magic_event_cb SXEmacs calls this with an event structure which
- contains window-system dependent information that
+ contains window-system dependent information that
SXEmacs doesn't need to know about, but which must
happen in order. If the next_event_cb never returns
an event of type "magic", this will never be used.
value it can deal with.
remove_timeout_cb Called with an int, the id number of a wakeup to
- discard. This id number must have been returned by
+ discard. This id number must have been returned by
the add_timeout_cb. If the given wakeup has
already expired, this should do nothing.
select_process_cb These callbacks tell the underlying implementation to
unselect_process_cb add or remove a file descriptor from the list of fds
- which are polled for inferior-process input. When
+ which are polled for inferior-process input. When
input becomes available on the given process
connection, an event of type "process" should be
generated.
select_console_cb These callbacks tell the underlying implementation
unselect_console_cb to add or remove a console from the list of consoles
- which are polled for user-input.
+ which are polled for user-input.
select_device_cb These callbacks are used by Unixoid event loops
unselect_device_cb (those that use select() and file descriptors and
If this is an integer, it will be in the printing
ASCII range: >32 and <127.
modifiers Bucky-bits on that key: control, meta, etc.
- Also includes buttons.
+ Also includes buttons.
For many keys, Shift is not a bit; that is implicit
in the keyboard layout.
button_release_event
button What button went down or up.
modifiers Bucky-bits on that button: shift, control, meta, etc.
- Also includes other buttons (not the one pressed).
+ Also includes other buttons (not the one pressed).
x, y Where it was at the button-state-change (in pixels).
pointer_motion_event
* Author: Sebastian Freundt <hroptatyr@sxemacs.org>
*
* This file is part of SXEmacs.
- *
+ *
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
eq_delegate_work(event_queue_t eq)
{
int cur = eq_queue_size(eq);
- while (cur--) {
+ while (cur--) {
eq_queue_trigger(eq);
}
return;
static void
eq_worker_th_blksig(void)
{
- EMACS_BLOCK_SIGNAL(SIGINT); /* ANSI */
- EMACS_BLOCK_SIGNAL(SIGILL); /* ANSI */
- EMACS_BLOCK_SIGNAL(SIGABRT); /* ANSI */
- EMACS_BLOCK_SIGNAL(SIGFPE); /* ANSI */
- EMACS_BLOCK_SIGNAL(SIGSEGV); /* ANSI */
- EMACS_BLOCK_SIGNAL(SIGTERM); /* ANSI */
-
+ EMACS_BLOCK_SIGNAL(SIGINT); /* ANSI */
+ EMACS_BLOCK_SIGNAL(SIGILL); /* ANSI */
+ EMACS_BLOCK_SIGNAL(SIGABRT); /* ANSI */
+ EMACS_BLOCK_SIGNAL(SIGFPE); /* ANSI */
+ EMACS_BLOCK_SIGNAL(SIGSEGV); /* ANSI */
+ EMACS_BLOCK_SIGNAL(SIGTERM); /* ANSI */
+
#if defined SIGHUP
- EMACS_BLOCK_SIGNAL(SIGHUP); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGHUP); /* POSIX */
#endif
#if defined SIGQUIT
- EMACS_BLOCK_SIGNAL(SIGQUIT); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGQUIT); /* POSIX */
#endif
#if defined SIGTRAP
- EMACS_BLOCK_SIGNAL(SIGTRAP); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGTRAP); /* POSIX */
#endif
#if defined SIGUSR1
- EMACS_BLOCK_SIGNAL(SIGUSR1); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGUSR1); /* POSIX */
#endif
#if defined SIGUSR2
- EMACS_BLOCK_SIGNAL(SIGUSR2); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGUSR2); /* POSIX */
#endif
#if defined SIGPIPE
- EMACS_BLOCK_SIGNAL(SIGPIPE); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGPIPE); /* POSIX */
#endif
#if defined SIGALRM
- EMACS_BLOCK_SIGNAL(SIGALRM); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGALRM); /* POSIX */
#endif
#if defined SIGCHLD
- EMACS_BLOCK_SIGNAL(SIGCHLD); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGCHLD); /* POSIX */
#endif
#if defined SIGCONT
- EMACS_BLOCK_SIGNAL(SIGCONT); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGCONT); /* POSIX */
#endif
#if defined SIGSTOP
- EMACS_BLOCK_SIGNAL(SIGSTOP); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGSTOP); /* POSIX */
#endif
#if defined SIGTSTP
- EMACS_BLOCK_SIGNAL(SIGTSTP); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGTSTP); /* POSIX */
#endif
#if defined SIGTTIN
- EMACS_BLOCK_SIGNAL(SIGTTIN); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGTTIN); /* POSIX */
#endif
#if defined SIGTTOU
- EMACS_BLOCK_SIGNAL(SIGTTOU); /* POSIX */
+ EMACS_BLOCK_SIGNAL(SIGTTOU); /* POSIX */
#endif
#if defined SIGBUS
- EMACS_BLOCK_SIGNAL(SIGBUS); /* XPG5 */
+ EMACS_BLOCK_SIGNAL(SIGBUS); /* XPG5 */
#endif
#if defined SIGPOLL
- EMACS_BLOCK_SIGNAL(SIGPOLL); /* XPG5 */
+ EMACS_BLOCK_SIGNAL(SIGPOLL); /* XPG5 */
#endif
#if defined SIGPROF
- EMACS_BLOCK_SIGNAL(SIGPROF); /* XPG5 */
+ EMACS_BLOCK_SIGNAL(SIGPROF); /* XPG5 */
#endif
#if defined SIGSYS
- EMACS_BLOCK_SIGNAL(SIGSYS); /* XPG5 */
+ EMACS_BLOCK_SIGNAL(SIGSYS); /* XPG5 */
#endif
#if defined SIGURG
- EMACS_BLOCK_SIGNAL(SIGURG); /* XPG5 */
+ EMACS_BLOCK_SIGNAL(SIGURG); /* XPG5 */
#endif
#if defined SIGXCPU
- EMACS_BLOCK_SIGNAL(SIGXCPU); /* XPG5 */
+ EMACS_BLOCK_SIGNAL(SIGXCPU); /* XPG5 */
#endif
#if defined SIGXFSZ
- EMACS_BLOCK_SIGNAL(SIGXFSZ); /* XPG5 */
+ EMACS_BLOCK_SIGNAL(SIGXFSZ); /* XPG5 */
#endif
#if defined SIGVTALRM
- EMACS_BLOCK_SIGNAL(SIGVTALRM); /* XPG5 */
+ EMACS_BLOCK_SIGNAL(SIGVTALRM); /* XPG5 */
#endif
#if defined SIGIO
- EMACS_BLOCK_SIGNAL(SIGIO); /* BSD 4.2 */
+ EMACS_BLOCK_SIGNAL(SIGIO); /* BSD 4.2 */
#endif
#if defined SIGWINCH
- EMACS_BLOCK_SIGNAL(SIGWINCH); /* BSD 4.3 */
+ EMACS_BLOCK_SIGNAL(SIGWINCH); /* BSD 4.3 */
#endif
#if defined SIGEMT
- EMACS_BLOCK_SIGNAL(SIGEMT);
+ EMACS_BLOCK_SIGNAL(SIGEMT);
#endif
#if defined SIGINFO
- EMACS_BLOCK_SIGNAL(SIGINFO);
+ EMACS_BLOCK_SIGNAL(SIGINFO);
#endif
#if defined SIGHWE
- EMACS_BLOCK_SIGNAL(SIGHWE);
+ EMACS_BLOCK_SIGNAL(SIGHWE);
#endif
#if defined SIGPRE
- EMACS_BLOCK_SIGNAL(SIGPRE);
+ EMACS_BLOCK_SIGNAL(SIGPRE);
#endif
#if defined SIGUME
- EMACS_BLOCK_SIGNAL(SIGUME);
+ EMACS_BLOCK_SIGNAL(SIGUME);
#endif
#if defined SIGDLK
- EMACS_BLOCK_SIGNAL(SIGDLK);
+ EMACS_BLOCK_SIGNAL(SIGDLK);
#endif
#if defined SIGCPULIM
- EMACS_BLOCK_SIGNAL(SIGCPULIM);
+ EMACS_BLOCK_SIGNAL(SIGCPULIM);
#endif
#if defined SIGIOT
- EMACS_BLOCK_SIGNAL(SIGIOT);
+ EMACS_BLOCK_SIGNAL(SIGIOT);
#endif
#if defined SIGLOST
# if !defined HAVE_BDWGC || !defined EF_USE_BDWGC
# endif /* BDWGC case */
#endif
#if defined SIGSTKFLT
- EMACS_BLOCK_SIGNAL(SIGSTKFLT);
+ EMACS_BLOCK_SIGNAL(SIGSTKFLT);
#endif
#if defined SIGUNUSED
- EMACS_BLOCK_SIGNAL(SIGUNUSED);
+ EMACS_BLOCK_SIGNAL(SIGUNUSED);
#endif
#if defined SIGDANGER
- EMACS_BLOCK_SIGNAL(SIGDANGER); /* AIX */
+ EMACS_BLOCK_SIGNAL(SIGDANGER); /* AIX */
#endif
#if defined SIGMSG
- EMACS_BLOCK_SIGNAL(SIGMSG);
+ EMACS_BLOCK_SIGNAL(SIGMSG);
#endif
#if defined SIGSOUND
- EMACS_BLOCK_SIGNAL(SIGSOUND);
+ EMACS_BLOCK_SIGNAL(SIGSOUND);
#endif
#if defined SIGRETRACT
- EMACS_BLOCK_SIGNAL(SIGRETRACT);
+ EMACS_BLOCK_SIGNAL(SIGRETRACT);
#endif
#if defined SIGGRANT
- EMACS_BLOCK_SIGNAL(SIGGRANT);
+ EMACS_BLOCK_SIGNAL(SIGGRANT);
#endif
#if defined SIGPWR
# if !defined HAVE_BDWGC || !defined EF_USE_BDWGC
- EMACS_BLOCK_SIGNAL(SIGPWR);
+ EMACS_BLOCK_SIGNAL(SIGPWR);
# endif /* BDWGC case */
#endif
}
work_handler_t hdl;
struct gcpro gcpro1;
- eq_worker_th_blksig();
+ eq_worker_th_blksig();
GCPRO1(ljob);
listen:
* Author: Sebastian Freundt <hroptatyr@sxemacs.org>
*
* This file is part of SXEmacs.
- *
+ *
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
Author: Sebastian Freundt <hroptatyr@sxemacs.org>
* This file is part of SXEmacs.
- *
+ *
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
Lisp_Object result = Qnil;
worker_job_t job;
- CHECK_WORKER_JOB(worker_job);
+ CHECK_WORKER_JOB(worker_job);
job = XWORKER_JOB(worker_job);
lock_worker_job(job);
result = worker_job_plist(job);
unlock_worker_job(job);
- return result;
+ return result;
}
static const struct lrecord_description worker_job_description[] = {
{XD_LISP_OBJECT, offsetof(struct worker_job_s, queue)},
- {XD_OPAQUE_DATA_PTR, offsetof(struct worker_job_s, handler)},
- {XD_OPAQUE_PTR, offsetof(struct worker_job_s, data)},
+ {XD_OPAQUE_DATA_PTR, offsetof(struct worker_job_s, handler)},
+ {XD_OPAQUE_PTR, offsetof(struct worker_job_s, data)},
#if !defined(EF_USE_POM) && defined(HAVE_THREADS)
- {XD_OPAQUE_PTR, offsetof(struct worker_job_s, mtx)},
+ {XD_OPAQUE_PTR, offsetof(struct worker_job_s, mtx)},
#endif
{XD_LISP_OBJECT, offsetof(struct worker_job_s, result)},
{XD_LISP_OBJECT, offsetof(struct worker_job_s, plist)},
{XD_INT, offsetof(struct worker_job_s, state)},
- {XD_OPAQUE_PTR, offsetof(struct worker_job_s, buffer)},
- {XD_SIZE_T, offsetof(struct worker_job_s, buffer_alloc_size)},
+ {XD_OPAQUE_PTR, offsetof(struct worker_job_s, buffer)},
+ {XD_SIZE_T, offsetof(struct worker_job_s, buffer_alloc_size)},
{XD_END}
};
Author: Sebastian Freundt <hroptatyr@sxemacs.org>
* This file is part of SXEmacs.
- *
+ *
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met: