comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » widget_control and group_leader
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
widget_control and group_leader [message #22928] Fri, 22 December 2000 14:06 Go to previous message
nrk5 is currently offline  nrk5
Messages: 7
Registered: December 2000
Junior Member
Lets say I have two widgets, A and B. There are two links between the
two:
1) A.top and B.top are eachother's groupleaders, and
2) A uses common blocks and has a variable 'foreign_event_handler' that
is set by B.

So, when an event is generated by A and the 'Use Foreign Event Handler'
option is set in the widget, events generated by A go to whatever B set
'foreign_event_handler' using:

widget_control, id, event_pro=foreign_event_handler

Things to note:
1) A can't be modified at all. Nothing added or changed. (ie. no more
variables)
2) B is an object widget and needs to set its structure variables to
variables in the events generated by A.
3) In B::init, B.top has a uvalue of self.

The question is, how can I use foreign_event_handler to get to 'B self'
from an event generated by A? My thought was:

PRO foreign_event_handler, eventFromA
widget_control, eventFromA.top, get_Group_Leader = BtopID
widget_control, BtopID, get_Uvalue = objectReferenceToB
...
END

And now I would be in business. But, is there such as thing as
get_group_leader? Is there another way to do this?

I know that not being able to change A doesn't help, else there would be
a million solutions, but its not my program. The only minor change I
might be able to make is to create a generic variable in A's common
block that could be set to whatever, but then I would have to define it
as a string or a long, and that would restrict its use.

Thanks much,


-- Nidhi
-----------------
Nidhi Kalra
nrk5@cornell.edu


Sent via Deja.com
http://www.deja.com/
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Speaking of RESTORING
Next Topic: Array-making speed

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 15:35:19 PDT 2025

Total time taken to generate the page: 0.48449 seconds