Re: [gtkmm] Signal emission stop
- From: SilvioCVdeAlmeida <scvalmei graaph arq br>
- To: "Andrew E. Makeev" <andrew solvo ru>
- Cc: gtkmm-main <gtkmm-list gnome org>
- Subject: Re: [gtkmm] Signal emission stop
- Date: Wed, 23 Apr 2003 15:30:44 -0300
>"Andrew E. Makeev" wrote:
>
> Look at the simple example below, and explain, please, how
> could I stop SigC signal emission?
Perhaps you can get the same effect by keeping the
SigC::Connection object (say con2) returned by the second
test_signal.connect method and then, inside fi(),
conditionally doing CON.disconnect();
Like this:
some_method ()
{
test_signal.connect (SigC::slot (*this, &MyClass::f1));
SigC::Connection con2 =
test_signal.connect (SigC::slot (*this, &MyClass::f2));
}
f1 ()
{
if (<expr> == true) con2.disconnect();
else
// ...
}
f2() { /* ... */ }
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]