Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
A Mediator Class
Message
De
08/06/1998 05:11:15
Mark Hall
Independent Developer & Voip Specialist
Keston, Kent, Royaume Uni
 
 
À
07/06/1998 08:43:03
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00105603
Message ID:
00105717
Vues:
23
>Heya All,
>
......Snip
>and then something like..
>
> loMediator = (.mcMediatorRef ) && or maybe EVAL()
> loMediator.RegisterMe(THIS.Class, THIS)
>
>But I wan't sure if this was the "proper" way
>
>Thanks,
Hi,
I think you could do this in two ways:
1) Have your mediator object connected to your application object (if you have one).
e.g.
goApplication.Mediator.RegisterMe(THIS.Class, THIS)
2) Have a Global mediator object that you create on application start-up, then just check for it's existance in the init of any object that might need to register itself.
e.g.
*-- Object Init code
IF TYPE( 'goMediator') = 'O' AND NOT ISNULL( loMediator)
goMediator.RegisterMe(THIS.Class, THIS)
ENDIF
Regards
Mark

Microsoft VFP MCP
Menulib - OO Menus for VFP www.hidb.com/menulib
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform