RE: [ROOT] multiple default parameters in slot

From: Faine, Valeri (fine@bnl.gov)
Date: Thu Mar 07 2002 - 22:41:42 MET


Hello Joe,
You should communicate the author of the software you are working
with first, namely Anton Fokin. He had asked this and he was replied:

Int_t Arg1=5;
SomeObject* Arg2=new SomeObject();

chart buffer[100]
sprintf(buffer,MethodWithArguments(=%d,=0x%), Arg1, Arg2); 

Connect(SomeClass,MethodWithoutArguments(),"MyClass",
this,buffer);

  Best regards, Valeri

 

-----Original Message-----
From: Joe Robe
To: roottalk@pcroot.cern.ch
Sent: 3/7/02 12:55 PM
Subject: [ROOT] multiple default parameters in slot

Hi rooters,

the docs show, that I can pass default parameters to a slot via using =
in
the parameter list.

Is there any way to use variables there and this also for MULTIPLE
arguments
??

What I want to do is something like:

Int_t Arg1=5;
SomeObject* Arg2=new SomeObject();

Connect(SomeClass,MethodWithoutArguments(),"MyClass",
this,"MethodWithArguments(=Arg1,=Arg2)");

MethodWithoutArguments is AWARE of Arg1 and Arg2, but I did not create
this
signal, just only have to use it and for whatever reason the developer
of
that signal does NOT submit this arguments !!

Any work around ??

Joe



_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com



This archive was generated by hypermail 2b29 : Sat Jan 04 2003 - 23:50:45 MET