OLD | NEW |
1 /* -*- c++ -*- | 1 /* -*- c++ -*- |
2 This file is part of LilyPond, the GNU music typesetter. | 2 This file is part of LilyPond, the GNU music typesetter. |
3 | 3 |
4 Copyright (C) 2005--2015 Han-Wen Nienhuys <hanwen@xs4all.nl> | 4 Copyright (C) 2005--2015 Han-Wen Nienhuys <hanwen@xs4all.nl> |
5 | 5 |
6 LilyPond is free software: you can redistribute it and/or modify | 6 LilyPond is free software: you can redistribute it and/or modify |
7 it under the terms of the GNU General Public License as published by | 7 it under the terms of the GNU General Public License as published by |
8 the Free Software Foundation, either version 3 of the License, or | 8 the Free Software Foundation, either version 3 of the License, or |
9 (at your option) any later version. | 9 (at your option) any later version. |
10 | 10 |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 \ | 92 \ |
93 ptrs[PROCESS_MUSIC] = \ | 93 ptrs[PROCESS_MUSIC] = \ |
94 method_finder <&T::process_music> (); \ | 94 method_finder <&T::process_music> (); \ |
95 \ | 95 \ |
96 ptrs[PROCESS_ACKNOWLEDGED] = \ | 96 ptrs[PROCESS_ACKNOWLEDGED] = \ |
97 method_finder <&T::process_acknowledged> (); \ | 97 method_finder <&T::process_acknowledged> (); \ |
98 } | 98 } |
99 | 99 |
100 void add_acknowledger (SCM ptr, | 100 void add_acknowledger (SCM ptr, |
101 char const *func_name, | 101 char const *func_name, |
102 Protected_scm &ack_hash); | 102 SCM &ack_hash); |
103 | 103 |
104 #define ADD_ACKNOWLEDGER(CLASS, NAME) \ | 104 #define ADD_ACKNOWLEDGER(CLASS, NAME) \ |
105 add_acknowledger (CLASS::ack_finder<&CLASS::acknowledge_ ## NAME> (), \ | 105 add_acknowledger (CLASS::ack_finder<&CLASS::acknowledge_ ## NAME> (), \ |
106 #NAME, CLASS::acknowledge_static_array_drul_[START]); | 106 #NAME, CLASS::acknowledge_static_array_drul_[START]); |
107 | 107 |
108 #define ADD_END_ACKNOWLEDGER(CLASS, NAME) \ | 108 #define ADD_END_ACKNOWLEDGER(CLASS, NAME) \ |
109 add_acknowledger (CLASS::ack_finder<&CLASS::acknowledge_end_ ## NAME> (), \ | 109 add_acknowledger (CLASS::ack_finder<&CLASS::acknowledge_end_ ## NAME> (), \ |
110 #NAME, CLASS::acknowledge_static_array_drul_[STOP]); | 110 #NAME, CLASS::acknowledge_static_array_drul_[STOP]); |
111 | 111 |
112 | 112 |
113 /* | 113 /* |
114 Implement the method cl::listen_##m, and make it listen to stream | 114 Implement the method cl::listen_##m, and make it listen to stream |
115 events of class m. | 115 events of class m. |
116 */ | 116 */ |
117 #define ADD_LISTENER(cl, m) \ | 117 #define ADD_LISTENER(cl, m) \ |
118 listener_list_ = scm_acons \ | 118 listener_list_ = scm_acons \ |
119 (event_class_symbol (#m), \ | 119 (event_class_symbol (#m), \ |
120 Callback_wrapper::make_smob \ | 120 Callback_wrapper::make_smob \ |
121 <trampoline <cl, &cl::listen_ ## m> > (), listener_list_); | 121 <trampoline <cl, &cl::listen_ ## m> > (), listener_list_); |
122 | 122 |
123 #endif /* TRANSLATOR_ICC */ | 123 #endif /* TRANSLATOR_ICC */ |
OLD | NEW |