home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!pipex!bnr.co.uk!uknet!comlab.ox.ac.uk!oxuniv!vollrath
- From: vollrath@vax.oxford.ac.uk
- Newsgroups: comp.sys.mac.programmer
- Subject: Re: Quick TCL Question
- Message-ID: <1992Dec23.165216.10982@vax.oxford.ac.uk>
- Date: 23 Dec 92 16:52:16 GMT
- References: <1992Dec22.015946.12196@rock.concert.net> <jpugh-211292224942@kip2-3.apple.com>
- Followup-To: comp.sys.mac.programmer
- Organization: Oxford University VAX 6620
- Lines: 30
-
- In article <jpugh-211292224942@kip2-3.apple.com>, jpugh@apple.com (Jon Pugh) writes:
- > In article <1992Dec22.015946.12196@rock.concert.net>, tbl@rock.concert.net
- > (Ted B Lowery -- Personal Account) wrote:
- >>
- >> Hi all,
- >>
- >> A quick question about the Think C Class Libraries. When my program starts,
- >> it is automatically sent a Open AppleEvent, which opens a blank document. I
- >> do not want a blank document automatically opened, so I want to stop this
- >> default action. But I cannot seem to find out how to do this without changing
- >> the core classes. How should I go about doing this?
- >
- > Override DoAppleEvent and make the same check the default method does, but
- > don't do anything. Pass all other cases.
- >
- > Jon
-
- Hi Ted,
- The problem with Jon's method, I think, is that most of the time you do want
- to respond to oApp events, for example if someone dragged a document onto
- your app's icon while you were switched out. You have to override Create
- Document anyway. When this is called from StartUpAction, the phase is
- appInitializing. I would check the phase in CreateDocument, and simply
- exit if you are in this phase. (I am using the Pascal version 1.1 of
- TCL, I presume this same system is used in the C version? Apologies for
- misleading you if it isn't)
-
- Alun ap Rhisiart
- Animal Behaviour Research Group
- Oxford University
-