comparison plugins/tcl/signal-test.tcl @ 8999:8f838ae3e710

[gaim-migrate @ 9774] " This patch renames the existing received-*-msg signals to receiving-*msg to fit the naming of other signals where a pointer to the message is passed (writing, sending, displaying) It adds new received-*-msg signals which are emitted after the receiving signals, in line with the other conversation signals (wrote, sent, displayed) This is necessary to allow plugins which depend on the final received message to work alongside plugins which may modify the message. One known example of this is festival-gaim alongside gaim-encryption - festival-gaim would try to "speak" the encrypted text: http://sf.net/tracker/?func=detail&aid=943216&group_id=89763&atid=591320 I've tested this with gaim-encryption and festival-gaim (locally modified so gaim-encryption uses the receiving signal and festival uses the received signal) All in-tree users of received-*-msg are updated to use receiving-*-msg if they do modify the message, the conversation-signals documentation is updated, the signals-test.c & signal-test.tcl plugins are also updated." --Stu Tomlinson committer: Tailor Script <tailor@pidgin.im>
author Luke Schierer <lschiere@pidgin.im>
date Fri, 21 May 2004 14:33:32 +0000
parents e280d73ed07f
children 60db14d54914
comparison
equal deleted inserted replaced
8998:3738d1eac0ad 8999:8f838ae3e710
44 44
45 gaim::signal connect [gaim::core handle] quitting {} { 45 gaim::signal connect [gaim::core handle] quitting {} {
46 gaim::debug -info "tcl signal" "quitting" 46 gaim::debug -info "tcl signal" "quitting"
47 } 47 }
48 48
49 gaim::signal connect [gaim::conversation handle] receiving-chat-msg { account who what id } {
50 gaim::debug -info "tcl signal" "receiving-chat-msg [gaim::account username $account] $id $who \"$what\""
51 return 0
52 }
53
54 gaim::signal connect [gaim::conversation handle] receiving-im-msg { account who what flags } {
55 gaim::debug -info "tcl signal" "receiving-im-msg [gaim::account username $account] $flags $who \"$what\""
56 return 0
57 }
58
49 gaim::signal connect [gaim::conversation handle] received-chat-msg { account who what id } { 59 gaim::signal connect [gaim::conversation handle] received-chat-msg { account who what id } {
50 gaim::debug -info "tcl signal" "received-chat-msg [gaim::account username $account] $id $who \"$what\"" 60 gaim::debug -info "tcl signal" "received-chat-msg [gaim::account username $account] $id $who \"$what\""
51 return 0
52 } 61 }
53 62
54 gaim::signal connect [gaim::conversation handle] received-im-msg { account who what flags } { 63 gaim::signal connect [gaim::conversation handle] received-im-msg { account who what flags } {
55 gaim::debug -info "tcl signal" "received-im-msg [gaim::account username $account] $flags $who \"$what\"" 64 gaim::debug -info "tcl signal" "received-im-msg [gaim::account username $account] $flags $who \"$what\""
56 return 0
57 } 65 }
58 66
59 gaim::signal connect [gaim::conversation handle] sending-chat-msg { account what id } { 67 gaim::signal connect [gaim::conversation handle] sending-chat-msg { account what id } {
60 gaim::debug -info "tcl signal" "sending-chat-msg [gaim::account username $account] $id \"$what\"" 68 gaim::debug -info "tcl signal" "sending-chat-msg [gaim::account username $account] $id \"$what\""
61 return 0 69 return 0