Mercurial > hg > xemacs-beta
comparison src/tooltalk.c @ 5027:22179cd0fe15
merge
author | Ben Wing <ben@xemacs.org> |
---|---|
date | Wed, 10 Feb 2010 07:25:19 -0600 |
parents | ae48681c47fa |
children | b5df3737028a |
comparison
equal
deleted
inserted
replaced
5026:46cf825f6158 | 5027:22179cd0fe15 |
---|---|
358 } | 358 } |
359 fprintf (tooltalk_log_file, "\n\n"); | 359 fprintf (tooltalk_log_file, "\n\n"); |
360 fflush (tooltalk_log_file); | 360 fflush (tooltalk_log_file); |
361 #endif | 361 #endif |
362 | 362 |
363 message_ = VOID_TO_LISP (tt_message_user (m, TOOLTALK_MESSAGE_KEY)); | 363 message_ = GET_LISP_FROM_VOID (tt_message_user (m, TOOLTALK_MESSAGE_KEY)); |
364 pattern = make_tooltalk_pattern (p); | 364 pattern = make_tooltalk_pattern (p); |
365 cb = XTOOLTALK_MESSAGE (message_)->callback; | 365 cb = XTOOLTALK_MESSAGE (message_)->callback; |
366 GCPRO2 (message_, pattern); | 366 GCPRO2 (message_, pattern); |
367 if (!NILP (Vtooltalk_message_handler_hook)) | 367 if (!NILP (Vtooltalk_message_handler_hook)) |
368 va_run_hook_with_args (Qtooltalk_message_handler_hook, 2, | 368 va_run_hook_with_args (Qtooltalk_message_handler_hook, 2, |
402 fprintf (tooltalk_log_file, "\n\n"); | 402 fprintf (tooltalk_log_file, "\n\n"); |
403 fflush (tooltalk_log_file); | 403 fflush (tooltalk_log_file); |
404 #endif | 404 #endif |
405 | 405 |
406 message_ = make_tooltalk_message (m); | 406 message_ = make_tooltalk_message (m); |
407 pattern = VOID_TO_LISP (tt_pattern_user (p, TOOLTALK_PATTERN_KEY)); | 407 pattern = GET_LISP_FROM_VOID (tt_pattern_user (p, TOOLTALK_PATTERN_KEY)); |
408 cb = XTOOLTALK_PATTERN (pattern)->callback; | 408 cb = XTOOLTALK_PATTERN (pattern)->callback; |
409 GCPRO2 (message_, pattern); | 409 GCPRO2 (message_, pattern); |
410 if (!NILP (Vtooltalk_pattern_handler_hook)) | 410 if (!NILP (Vtooltalk_pattern_handler_hook)) |
411 va_run_hook_with_args (Qtooltalk_pattern_handler_hook, 2, | 411 va_run_hook_with_args (Qtooltalk_pattern_handler_hook, 2, |
412 message_, pattern); | 412 message_, pattern); |
862 if (NILP (no_callback)) | 862 if (NILP (no_callback)) |
863 { | 863 { |
864 tt_message_callback_add (m, tooltalk_message_callback); | 864 tt_message_callback_add (m, tooltalk_message_callback); |
865 } | 865 } |
866 tt_message_session_set (m, tt_default_session ()); | 866 tt_message_session_set (m, tt_default_session ()); |
867 tt_message_user_set (m, TOOLTALK_MESSAGE_KEY, LISP_TO_VOID (message_)); | 867 tt_message_user_set (m, TOOLTALK_MESSAGE_KEY, STORE_LISP_IN_VOID (message_)); |
868 return message_; | 868 return message_; |
869 } | 869 } |
870 | 870 |
871 DEFUN ("destroy-tooltalk-message", Fdestroy_tooltalk_message, 1, 1, 0, /* | 871 DEFUN ("destroy-tooltalk-message", Fdestroy_tooltalk_message, 1, 1, 0, /* |
872 Apply tt_message_destroy() to the message. | 872 Apply tt_message_destroy() to the message. |
970 Tt_pattern p = tt_pattern_create (); | 970 Tt_pattern p = tt_pattern_create (); |
971 Lisp_Object pattern = make_tooltalk_pattern (p); | 971 Lisp_Object pattern = make_tooltalk_pattern (p); |
972 | 972 |
973 tt_pattern_callback_add (p, tooltalk_pattern_callback); | 973 tt_pattern_callback_add (p, tooltalk_pattern_callback); |
974 tt_pattern_session_add (p, tt_default_session ()); | 974 tt_pattern_session_add (p, tt_default_session ()); |
975 tt_pattern_user_set (p, TOOLTALK_PATTERN_KEY, LISP_TO_VOID (pattern)); | 975 tt_pattern_user_set (p, TOOLTALK_PATTERN_KEY, STORE_LISP_IN_VOID (pattern)); |
976 | 976 |
977 return pattern; | 977 return pattern; |
978 } | 978 } |
979 | 979 |
980 | 980 |