Path: news.cs.au.dk!noatun.mjolner.dk!mail-to-news From: Atle Newsgroups: comp.lang.beta Subject: Re: More GUI Date: Tue, 07 Nov 2000 19:56:22 +0100 Organization: Posted to comp.lang.beta by a mailtonews script Lines: 47 Sender: lbr@mjolner.dk Approved: mailtonews@cs.au.dk Message-ID: <8ub1kl$66iat$1@gjallar.cs.au.dk> References: <3A083686.C03A34DE@skynet.be> <20001107174041.C19335@mjolner.dk> NNTP-Posting-Host: bifrost.mjolner.dk Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: gjallar.cs.au.dk 973670869 6506845 130.225.8.27 (8 Nov 2000 08:07:49 GMT) X-Complaints-To: usenet@cs.au.dk NNTP-Posting-Date: Wed, 8 Nov 2000 08:07:49 +0000 (UTC) Mailing-List: contact usergroup-help@mjolner.dk; run by ezmlm X-No-Archive: yes X-Mailer: Mozilla 4.72 [en] (X11; U; Linux 2.2.14 i686) X-Accept-Language: en X-Original-Message-ID: <3A085056.20BF7FBD@skynet.be> X-Original-Sender: atle@skynet.be Xref: news.cs.au.dk comp.lang.beta:12636 Flemming Gram Christensen wrote: > > > And therefore, the decision to 'Generate Diagnosis' should be taken in acubase.bet? > > Yes, I think it should. > > > > > Of course, it will work either way, but this being a 'case study' :-) > > Please allways do things like that. (not only in gui programs) What I am trying to do, is do what I used to do in C, wheren 'control variables' were passed back and forth to keep the semantics straight. In general, a 'control variable' can be a return value or some flag, but is actually an artificial thing, because it is not there to hold a value, just to track and specify behaviour. Can I assume that the 'normal way' of doing this in Beta is with virtual functions? I think I remember an article about this, but I have completely forgotten where and when ... > > Here is an example: > > SymptomWindow : window > (# > (* will be called when user presses 'Generate Diagnosis' PushButton, or something) *) > openDiagnosticsWindow: onMouseUp::(# do (* call the virtual callback *) > openDiagnosticsWindow .... here is the on/off switch .... > Sympt : @SymptomsWindow > (# openDiagnosticsWindow::< .... and this is the 'plug' with the attached 'apparatus' ... > (# > do (* some code to set up current diagnostics *) > Diag.show; > #) This looks general enough that I can use it throughout the whole program, right? (I plan on equipping the system with 'outlets' for 'apparatus' to store data for different patients, a 'patient register') BTW: Do you know of someone who might want to use a system like this? Atle