Home » U++ Library support » U++ Core » <<= and <<
Re: <<= and << [message #7184 is a reply to message #7183] |
Sun, 17 December 2006 23:57   |
Balage
Messages: 17 Registered: December 2006
|
Promising Member |
|
|
I was just curious, as both worked fine, and produced the same result, I just didn't know what was the diff.
Actually, somebutton << THISBACK(Press) does work!
class Ctrl has these operators:
Callback operator<<=(Callback action) { WhenAction = action; return action; }
Callback& operator<<(Callback action) { return WhenAction << action; }
I tried this:
somebutton << THISBACK(Press) << THISBACK(Press2) << THISBACK(Press3) << THISBACK(Press);
The handlers were called in this order:
Press, Press2, Press3, Press
So with <<, I can add multiple callbacks. That's nice.
[Updated on: Mon, 18 December 2006 00:01] Report message to a moderator
|
|
|
 |
|
<<= and <<
By: Balage on Sun, 17 December 2006 23:12
|
 |
|
Re: <<= and <<
By: mirek on Sun, 17 December 2006 23:48
|
 |
|
Re: <<= and <<
By: Balage on Sun, 17 December 2006 23:57
|
 |
|
Re: <<= and <<
By: mirek on Mon, 18 December 2006 00:16
|
 |
|
Re: <<= and <<
By: waxblood on Fri, 30 November 2007 13:13
|
 |
|
Re: <<= and <<
By: mirek on Fri, 30 November 2007 13:52
|
 |
|
Re: <<= and <<
By: waxblood on Thu, 06 December 2007 23:44
|
 |
|
Re: <<= and <<
By: mirek on Fri, 07 December 2007 09:25
|
 |
|
Re: <<= and <<
By: waxblood on Fri, 07 December 2007 10:12
|
 |
|
Re: <<= and <<
By: mirek on Sat, 08 December 2007 07:17
|
Goto Forum:
Current Time: Mon Apr 28 23:10:32 CEST 2025
Total time taken to generate the page: 0.02964 seconds
|