On Wed, May 20, 2015 at 3:20 PM, Peter Dimov
Edward Diener wrote:
I understand that with Synapse you are merely making a call at a
convenient point in order to emit a signal, whereas with signals2 you need to have a boost::signals2::signal object somewhere for the particular signal triggering before you can emit a signal or have connections to handle the signal. But in Synapse you also must have a signal emitter which is accesible for the event handlers making the connection to the event. This to me is equivalent to boost::signals2 having a signal object.
You can use an already existing object as the emitter, such as a HWND, or a third-party UI button object.
Yes, for example it is not at all trivial to pass some kind of (emitter) object down to a WindowProc. With Synapse you don't have to, you can call emit<> on the HWND object directly, as in http://revergestudios.com/boost-synapse/using_Boost_Synapse_to_handle_events... . Emil Dotchevski Reverge Studios, Inc. http://www.revergestudios.com/reblog/index.php?n=ReCode