home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!mcsun!news.funet.fi!ajk.tele.fi!funic!sauna.cs.hut.fi!cs.hut.fi!jtp
- From: jtp@cs.hut.fi (Jukka Partanen)
- Newsgroups: comp.sys.amiga.programmer
- Subject: LockIBase
- Date: 23 Dec 1992 00:55:28 GMT
- Organization: Helsinki University of Technology, Finland
- Lines: 24
- Distribution: comp
- Message-ID: <JTP.92Dec23025528@laphroaig.cs.hut.fi>
- NNTP-Posting-Host: laphroaig.cs.hut.fi
-
-
- What's the correct locking protocol if one wants to find a
- particular screen, and then do something with it? The RKM
- states that one shouldn't call any high level calls while
- holding the IntuitionBase lock.
-
- Currently I'm using
-
- LockIBase();
- Find_The_Screen;
- Forbid(); /* so it won't be closed */
- UnlockIBase();
- Do_The_Magic_Involving_High_Level_Calls;
- Permit();
-
- but this seems very ugly to me. Isn't there a better way to
- make sure that a particular screen (not necessarily a public
- screen) isn't closed while I'm referencing it?
-
- Thanks,
- jtp
-
- Zippy quotation:
- - if it GLISTENS, gobble it!!
-